[gegl] gegl-chant: use g_value_dup_string() instead of strdup(get_string())



commit e1a6fe8eebfd449641693f6a49666ffbffb9e178
Author: Michael Natterer <mitch gimp org>
Date:   Wed Dec 4 23:20:23 2013 +0100

    gegl-chant: use g_value_dup_string() instead of strdup(get_string())

 gegl/gegl-chant.h |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/gegl/gegl-chant.h b/gegl/gegl-chant.h
index 007bc2d..d8c7906 100644
--- a/gegl/gegl-chant.h
+++ b/gegl/gegl-chant.h
@@ -640,9 +640,9 @@ set_property (GObject      *gobject,
     case PROP_##name:                                                 \
       if (properties->name)                                           \
         g_free (properties->name);                                    \
-      properties->name = g_strdup (g_value_get_string (value));       \
+      properties->name = g_value_dup_string (value);                  \
       break;
-#define gegl_chant_enum(name, nick, enum, enum_name, def, blurb)          \
+#define gegl_chant_enum(name, nick, enum, enum_name, def, blurb)      \
     case PROP_##name:                                                 \
       properties->name = g_value_get_enum (value);                    \
       break;
@@ -650,13 +650,13 @@ set_property (GObject      *gobject,
     case PROP_##name:                                                 \
       if (properties->name)                                           \
         g_free (properties->name);                                    \
-      properties->name = g_strdup (g_value_get_string (value));       \
+      properties->name = g_value_dup_string (value);                  \
       break;
 #define gegl_chant_multiline(name, nick, def, blurb)                  \
     case PROP_##name:                                                 \
       if (properties->name)                                           \
         g_free (properties->name);                                    \
-      properties->name = g_strdup (g_value_get_string (value));       \
+      properties->name = g_value_dup_string (value);                  \
       break;
 #define gegl_chant_object(name, nick, blurb)                          \
     case PROP_##name:                                                 \


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]