[Flac-dev] flac reports error unnecessarily

Josh Coalson xflac at yahoo.com
Wed Jul 21 17:23:47 PDT 2004


--- Kevin Kleinfelter <flac-dev at kleinfelter.com> wrote:
> I'm embedding flac in a Samba VFS application.  flac gets called to 
> decompress files, which Samba serves up to the client as WAV files. 
> Every 
> time a Windows client browses a folder, it opens music files to read
> the 
> header, and then it closes them without reading the entire file.  I'm
> 
> accessing flac via popen/pclose.
> 
> Each time I close the pipe to flac 'prematurely' (i.e. before flac
> has 
> decoded the entire file) it issues "ERROR while decoding data"
> because 
> FLAC__file_decoder_process_until_end_of_file returns an error
> indication.
> 
> As a quick hack, I added a check for errno == EPIPE in decode.c. 
> This 
> solves *my* immediate problem.
> 
> I propose that, when output is to stdout, 
> FLAC__file_decoder_process_until_end_of_file should not return an
> error 
> indication on a broken output pipe, because pipes get broken all the
> time.

OK, I finally got around to fixing this.  it's in CVS now; let
me know after the next release if it's still broken.

Josh


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 




More information about the Flac-dev mailing list