buffer: fix copy meta reference debug log formatting
authorJames Hilliard <james.hilliard1@gmail.com>
Wed, 22 Feb 2023 03:13:57 +0000 (20:13 -0700)
committerGStreamer Marge Bot <gitlab-merge-bot@gstreamer-foundation.org>
Sat, 25 Feb 2023 11:46:14 +0000 (11:46 +0000)
Fixes the following valgrind error:
==616== Conditional jump or move depends on uninitialised value(s)
==616==    at 0x4900E34: gst_debug_print_object (gstinfo.c:1143)
==616==    by 0x49010B6: gst_info_printf_pointer_extension_func (gstinfo.c:1215)
==616==    by 0x4959FDB: __gst_printf_pointer_extension_serialize (printf-extension.c:47)
==616==    by 0x495A487: printf_postprocess_args (vasnprintf.c:258)
==616==    by 0x495A52C: __gst_vasnprintf (vasnprintf.c:290)
==616==    by 0x4959F8F: __gst_vasprintf (printf.c:154)
==616==    by 0x4901C1F: gst_debug_message_get (gstinfo.c:791)
==616==    by 0x4901C75: _gst_debug_log_preamble (gstinfo.c:1431)
==616==    by 0x4903208: gst_debug_log_default (gstinfo.c:1575)
==616==    by 0x49020BA: gst_debug_log_full_valist (gstinfo.c:624)
==616==    by 0x490211D: gst_debug_log_valist (gstinfo.c:656)
==616==    by 0x49021AD: gst_debug_log (gstinfo.c:533)
==616==    by 0x48DDC11: gst_buffer_copy_into (gstbuffer.c:693)
==616==    by 0x48DF5F1: gst_buffer_copy_with_flags (gstbuffer.c:727)
==616==    by 0x48DF640: gst_buffer_copy_deep (gstbuffer.c:756)

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4038>

subprojects/gstreamer/gst/gstbuffer.c

index fb2c787..13bf9c8 100644 (file)
@@ -691,7 +691,8 @@ gst_buffer_copy_into (GstBuffer * dest, GstBuffer * src,
       } else if (deep && gst_meta_api_type_has_tag (info->api,
               _gst_meta_tag_memory_reference)) {
         GST_CAT_DEBUG (GST_CAT_BUFFER,
-            "don't copy meta with memory references %" GST_PTR_FORMAT, meta);
+            "don't copy memory reference meta %p of API type %s", meta,
+            g_type_name (info->api));
       } else if (info->transform_func) {
         GstMetaTransformCopy copy_data;