[gstreamer-bugs] [Bug 335365] New: bad use of GList in gst-plugins-base

GStreamer (bugzilla.gnome.org) bugzilla-daemon at bugzilla.gnome.org
Tue Mar 21 06:55:45 PST 2006


Do not reply to this via email (we are currently unable to handle email
responses and they get discarded).  You can add comments to this bug at
http://bugzilla.gnome.org/show_bug.cgi?id=335365
 GStreamer | gst-plugins-base | Ver: HEAD CVS

           Summary: bad use of GList in gst-plugins-base
           Product: GStreamer
           Version: HEAD CVS
          Platform: Other
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: Normal
         Component: gst-plugins-base
        AssignedTo: gstreamer-bugs at lists.sourceforge.net
        ReportedBy: pborelli at katamail.com
         QAContact: gstreamer-bugs at lists.sourceforge.net
     GNOME version: Unspecified
   GNOME milestone: Unspecified


excerpt of the interesting part of find gst-plugins-base/ -name "*\.c" | xargs
egrep "\bfor [(].*[(]"

Measuring the list lenght at each iteration doesn't sound like a good idea
(unless the list lenght changes in the for body). Measuring should be factored
out of the loop.
I also inclueded loops doing gst_caps_get_size etc, but maybe those are O(1)
and are ok.


gst-plugins-base/ext/alsa/gstalsasink.c:  for (i = 0; i < gst_caps_get_size
(tmpl_caps); ++i) {
gst-plugins-base/ext/ogg/gstoggparse.c:  for (i = 0; i < g_slist_length
(parser->oggstreams); i++) {
gst-plugins-base/ext/ogg/gstoggparse.c:            for (i = 0; i <
g_slist_length (ogg->oggstreams); i++) {
gst-plugins-base/ext/ogg/gstoggparse.c:            for (i = 0; i <
g_slist_length (ogg->oggstreams); i++) {
gst-plugins-base/ext/ogg/gstoggparse.c:              for (j = 1; j <
g_slist_length (stream->headers); j++) {
gst-plugins-base/ext/ogg/gstoggparse.c:            for (i = 0; i <
g_slist_length (ogg->oggstreams); i++) {
gst-plugins-base/ext/ogg/gstoggparse.c:            for (i = 0; i <
g_slist_length (ogg->oggstreams); i++) {
gst-plugins-base/ext/ogg/gstoggparse.c:              for (j = 1; j <
g_slist_length (stream->headers); j++) {
gst-plugins-base/ext/ogg/gstoggparse.c:            for (i = 0; i <
g_slist_length (ogg->oggstreams); i++) {
gst-plugins-base/ext/ogg/gstoggparse.c:              for (j = 0; j <
g_slist_length (stream->unknown_pages); j++) {
gst-plugins-base/ext/libvisual/visual.c:  for (i = 0; i < visual_list_count
(list); i++) {
gst-plugins-base/gst/audioconvert/gstaudioconvert.c:  for (i = 0; i <
gst_caps_get_size (ret); ++i) {
gst-plugins-base/gst/ffmpegcolorspace/gstffmpegcolorspace.c:  for (i = 0; i <
gst_caps_get_size (caps); i++) {
gst-plugins-base/gst/ffmpegcolorspace/gstffmpegcolorspace.c:  for (i = 0; i <
gst_caps_get_size (rgbcaps); i++) {
gst-plugins-base/gst/ffmpegcolorspace/gstffmpegcolorspace.c:  for (i = 0; i <
gst_caps_get_size (graycaps); i++) {
gst-plugins-base/gst/playback/gstplaybasebin.c:          for (i = 0; i <
gst_caps_get_size (caps); ++i) {
gst-plugins-base/gst/videorate/gstvideorate.c:  for (i = 0; i <
gst_caps_get_size (intersect); i++) {
gst-plugins-base/gst/videoscale/gstvideoscale.c:  for (i = 0; i <
gst_caps_get_size (ret); i++) {
gst-plugins-base/gst-libs/gst/audio/multichannel.c:        for (c = 0; c <
gst_value_list_get_size (pos_val_entry); c++) {
gst-plugins-base/gst-libs/gst/audio/multichannel.c:                for (c1 = 0;
c1 < gst_value_list_get_size (pos_val_entry); c1++) {
gst-plugins-base/gst-libs/gst/tag/gstvorbistag.c:  for (i = 0; i <
gst_tag_list_get_tag_size (list, tag); i++) {
gst-plugins-base/sys/v4l/gstv4lsrc.c:  for (i = 0; i < gst_caps_get_size
(caps); ++i) {
gst-plugins-base/sys/v4l/v4l_calls.c:  for (i = 0; i < gst_v4l_get_num_chans
(v4lelement); i++) {


-- 
Configure bugmail: http://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.




More information about the Gstreamer-bugs mailing list