From f72116833d67c954ec69dfe8aced4e7e26c36c23 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Tue, 3 Aug 2010 17:09:57 -0500 Subject: Turning null strings into NULLs --- src/app-indicator.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/app-indicator.c b/src/app-indicator.c index 0da0b01..b3fa3e5 100644 --- a/src/app-indicator.c +++ b/src/app-indicator.c @@ -651,6 +651,11 @@ app_indicator_set_property (GObject * object, guint prop_id, const GValue * valu signal_label_change(APP_INDICATOR(object)); } + if (priv->label != NULL && priv->label[0] == '\0') { + g_free(priv->label); + priv->label = NULL; + } + if (oldlabel != NULL) { g_free(oldlabel); } @@ -664,6 +669,11 @@ app_indicator_set_property (GObject * object, guint prop_id, const GValue * valu signal_label_change(APP_INDICATOR(object)); } + if (priv->label_guide != NULL && priv->label_guide[0] == '\0') { + g_free(priv->label_guide); + priv->label_guide = NULL; + } + if (oldguide != NULL) { g_free(oldguide); } -- cgit v1.2.3