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 315144 - gstreamer-cdparanoia gst_pad_query invalid data
gstreamer-cdparanoia gst_pad_query invalid data
Status: RESOLVED DUPLICATE of bug 313209
Product: GStreamer
Classification: Platform
Component: gst-plugins
0.8.10
Other Linux
: Urgent major
: 0.8.12
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2005-09-02 19:14 UTC by Aaron Bockover
Modified: 2005-10-06 15:05 UTC
See Also:
GNOME target: ---
GNOME version: 2.11/2.12


Attachments
Source to testcase demonstrating bug (1.69 KB, text/plain)
2005-09-02 19:15 UTC, Aaron Bockover
  Details
Patch against our gstreamer-plugins package, fixes the bug. (1.40 KB, patch)
2005-09-02 19:18 UTC, Aaron Bockover
none Details | Review

Description Aaron Bockover 2005-09-02 19:14:10 UTC
Distribution/Version: SuSE 10 Beta 3

The gstreamer-cdparanoia plugin reports invalid sector data (always 0) on
gst_pad_query() calls for getting disk/track information which is needed to
calculate offsets and track durations for CD tracks. The problem also affects
Goobox, and has been confirmed on SuSE 10, Ubuntu Breezy, and Foresight Linux.

The problem was patched, and the bug we filed internally for getting Banshee to
work is here:
https://bugzilla.novell.com/show_bug.cgi?id=113937
Comment 1 Aaron Bockover 2005-09-02 19:15:30 UTC
Created attachment 51735 [details]
Source to testcase demonstrating bug

Just running this testcase should exhibit the bug: total_sectors will be 0,
while n_tracks should be correct: the number of tracks on the audio CD being
tested (/dev/hdc by default). Compile, insert audio CD, wait for it to spin and
settle, and then run the program.
Comment 2 Aaron Bockover 2005-09-02 19:18:29 UTC
Created attachment 51736 [details] [review]
Patch against our gstreamer-plugins package, fixes the bug.

(This paraphrases hpj's comments regarding his attached patch)

Here's a patch that fixes the problem with GStreamer's cdparanoia plugin. The
bug is entirely in the plugin, and not caused by any inconsistency in
cdparanoia.

The problem was that the plugin has to be in "track mode" for a support
function, get_first_sector(), to return a non-zero value for sector count. It
will then return the sector count of the passed-in track.

I just made an exception so that if not in "track mode", it returns the sector
count of the entire CD, just as it will return the total number of tracks if
that's what you ask for. I changed the reporting function, not
get_first_sector() itself, because there is too much code depending on it.
Comment 3 Ronald Bultje 2005-09-02 23:59:01 UTC
Please confirm that this doesn't break gnome-cd, sound-juicer or totem. Each of
them has very fragile ( :-( ) interaction with this plugin when it comes to
getting per-track playback, per-track seeking, track-transitions etc. right.
Comment 4 Aaron Bockover 2005-09-03 00:19:45 UTC
Should have mentioned that I also tested those three, plus goobox. All four
applications work fine for CD playback, and each application reports correct
track durations, and can seek to and within tracks. Neither sound-juicer,
gnome-cd, nor totem ever had a problem getting sector information before this
patch, and the patch does not prevent them from doing so now.
Comment 5 Luca Ognibene 2005-09-22 19:32:40 UTC
I think there's a similar patch at bug #313209. Are the patch fixing the same
bug ? (i've not looked closely at them yet). thanks!
Comment 6 Andy Wingo 2005-10-06 14:20:53 UTC
I like the approach of bug #313209 better. I have tested it and verified that it
works with sound-juicer and totem. gnome-cd has never worked for me. Closing
this bug as a dup.

*** This bug has been marked as a duplicate of 313209 ***