Gstreamer apps halt decoding FLAC files on checksum error

Bug #163473 reported by Philip Kovac
4
Affects Status Importance Assigned to Milestone
gst-plugins (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Binary package hint: gstreamer-flac

Totem, Rhythmbox, and presumably other gstreamer-utilizing applications will not make a "best effort" at decoding a FLAC file for playback if CRC fails; a moderately corrupted, but otherwise playable file, will be rendered unusable.

Steps to reproduce:
1) Find/create a FLAC file that contains a CRC error
2) Load file in Rhythmbox or Totem
3) Play file
4) Player will stop midway through the track (where the error occurs,) and pop up a dialog box saying "An error occured: Could not decode stream." A message appears on stderr:
** Message: Error: Could not decode stream.
gstflacdec.c(634): gst_flac_dec_error_callback (): /play/decodebin0/flacdec0:
CRC mismatch (2)

Suggested behavior:
4) Player skips or attempts to decode the frame for which the checksum failed; still print error to stderr.

If my understand of the way GStreamer pipelines work is correct, always ignoring checksum errors would be a Bad Thing. It would result in one of the "main features" of FLAC becoming untrue of gstreamer pipelines used to transcode it, namely, guaranteed data integrity. However, it should be somehow possible to allow for the FLAC plugin to ignore errors in certain cases.

Revision history for this message
Philip Kovac (pkovac) wrote :

It should be noted that flac123 somehow seems to skip the bad frame on the track in question. Though the gap is noticable, it is a far less disruptive behavior than stopping playback entirely.

Revision history for this message
David Nielsen (davidnielsen-deactivatedaccount) wrote :

Are we sure the crc error is genuine in the first place. I have a big catalog of FLAC tunes and on my Fedora box Banshee does not throw the dreaded: "gstflacdec.c(769): gst_flac_dec_error_callback (): /pipeline/decodebin/flacdec2: unknown error (3)" whereas the same collection on Intrepid does.

This is using Banshee to do the transcoding to my iPod in both cases.

Daniel T Chen (crimsun)
Changed in gst-plugins:
status: New → Confirmed
Revision history for this message
Mr.Mizzen (mr-mizzen) wrote :

Ubuntu 9.10 AMD64

Rhythmbox reported an error on the file somewhere_in_a_dream.flac about 3/4 through.

If I use Mplayer the output shows no error and plays the file completely.

root@Imperial-Command:/Archive/0# mplayer somewhere_in_a_dream.flac
MPlayer UNKNOWN-4.4.1 (C) 2000-2009 MPlayer Team
mplayer: could not connect to socket
mplayer: No such file or directory
Failed to open LIRC support. You will not be able to use your remote control.

Playing somewhere_in_a_dream.flac.
Audio only file format detected.
==========================================================================
Opening audio decoder: [ffmpeg] FFmpeg/libavcodec audio decoders
AUDIO: 44100 Hz, 2 ch, s16le, 828.8 kbit/58.73% (ratio: 103598->176400)
Selected audio codec: [ffflac] afm: ffmpeg (FFmpeg FLAC audio)
==========================================================================
[pulse] working around probably broken pause functionality,
        see http://www.pulseaudio.org/ticket/440
AO: [pulse] 44100Hz 2ch s16le (2 bytes per sample)
Video: no video
Starting playback...
A: 252.3 (04:12.2) of 249.0 (04:09.0) 0.4%
Exiting... (End of file)

The same file with totem, plays about 3/4 then dies with this:

root@Imperial-Command:/Archive/0# totem somewhere_in_a_dream.flac
** Message: Error: Could not decode stream.
gstflacdec.c(660): gst_flac_dec_error_cb (): /GstPlayBin2:play/GstURIDecodeBin:uridecodebin0/GstDecodeBin2:decodebin20/GstFlacDec:flacdec0:
CRC mismatch (2)

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.