After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 574241 - gst_tag_list_add and gst_tag_list_add_values behave inconsistently for GST_TAG_MERGE_REPLACE_ALL
gst_tag_list_add and gst_tag_list_add_values behave inconsistently for GST_TA...
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
0.10.22
Other All
: Normal normal
: 0.10.23
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2009-03-05 10:36 UTC by Roderich Schupp
Modified: 2009-03-12 12:48 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Roderich Schupp 2009-03-05 10:36:43 UTC
gst_tag_list_add and gst_tag_list_add_values (and their
*_valist variants) behave inconsistently when the
merge mode is GST_TAG_MERGE_REPLACE_ALL:

gst_tag_list_add clears the _whole_ tag list (and not
just the tags I'm trying to add) before adding 
the new tags. OTOH gst_tag_list_add_values doesn't
affect tags already present on tga list that 
are different from the tags I'm trying to add.

IMHO gst_tag_list_add gets it right according to the 
documentation about GST_TAG_MERGE_REPLACE_ALL. 

The difference between the two functions are these lines
at the start of gst_tag_list_add_valist:

  if (mode == GST_TAG_MERGE_REPLACE_ALL) {
    gst_structure_remove_all_fields (list);
  }
Comment 1 Roderich Schupp 2009-03-05 13:13:38 UTC
FYI: The above change to gst/gsttaglist.c was introduced in this commit
http://cgit.freedesktop.org/gstreamer/gstreamer/commit/?id=f28a2a6cfc7e69279c5bda8bbdcf31039d99487f
Comment 2 Stefan Sauer (gstreamer, gtkdoc dev) 2009-03-12 12:48:16 UTC
You are right. Thanks!
commit c3286501b4123ba0886558ebc4900c2eb49d8357
Author: Stefan Kost <ensonic@users.sf.net>
Date:   Thu Mar 12 12:20:25 2009 +0200

    taglists: apply fix for replace all also to gst_tag_list_add_valist_values. Fixes #574241