diff options
Diffstat (limited to 'src/mesa/main')
-rw-r--r-- | src/mesa/main/objectlabel.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/mesa/main/objectlabel.c b/src/mesa/main/objectlabel.c index 8efc33e0dd0..efa7ba8d19a 100644 --- a/src/mesa/main/objectlabel.c +++ b/src/mesa/main/objectlabel.c @@ -45,11 +45,8 @@ static void set_label(struct gl_context *ctx, char **labelPtr, const char *label, int length, const char *caller) { - if (*labelPtr) { - /* free old label string */ - free(*labelPtr); - *labelPtr = NULL; - } + free(*labelPtr); + *labelPtr = NULL; /* set new label string */ if (label) { |