gstobject: fix double string escaping in gst_object_default_deep_notify()

Make output of gst-launch -v readable again.

last-message = "event\ \ \ \*\*\*\*\*\*\*\ \(fakesink0:sink\)\ E\ \(type:\ tag\ \(20510\)\,\ GstTagList-stream\,\ taglist\=\(taglist\)\"taglist\\\,\\\ video-codec\\\=\\\(string\\\)H264\\\,\\\
 minimum-bitrate\\\=\\\(uint\\\)636611\\\,\\\ bitrate\\\=\\\(uint\\\)980729\\\,\\\ maximum-bitrate\\\=\\\(uint\\\)1116707\\\;\"\;\)\ 0x15bc760"

vs.

last-message = event   ******* (fakesink0:sink) E (type: tag (20510), GstTagList-stream, taglist=(taglist)"taglist\,\ video-codec\=\(string\)H264\,\ minimum-bitrate\=\(uint\)856039\,\ bitrate
\=\(uint\)1019748\,\ maximum-bitrate\=\(uint\)1116707\;";) 0x11149e0
This commit is contained in:
Tim-Philipp Müller 2012-08-09 19:15:29 +01:00
parent 97441c27ee
commit 690a20a54d

View file

@ -507,7 +507,10 @@ gst_object_default_deep_notify (GObject * object, GstObject * orig,
g_value_init (&value, pspec->value_type);
g_object_get_property (G_OBJECT (orig), pspec->name, &value);
str = gst_value_serialize (&value);
if (G_VALUE_HOLDS_STRING (&value))
str = g_value_dup_string (&value);
else
str = gst_value_serialize (&value);
name = gst_object_get_path_string (orig);
g_print ("%s: %s = %s\n", name, pspec->name, str);
g_free (name);