[vorbis-dev] Ogg Open Crash
Monty
monty at xiph.org
Mon Sep 10 09:40:05 PDT 2001
I'm not a Win32 developer (no Win boxes right here), and debugging
style mails are generally not best sent directly to me as I'm
currently sporting a 2000 message backlog in my inbox. I've taken the
liberty of forwarding this the the development list.
On Sat, Sep 08, 2001 at 05:14:41PM +0200, Nikolaus Brennig wrote:
> Hello!
>
> Today i wanted to implement ogg vorbis support in my app (www.slowview.f2s.com).
> So i downloaded the ogg vorbis sdk rc2 for win32. I've looked in the code and decided the easiest way is to just use the MediaXW codecs to play ogg files via the mci interface. Works fine so far. But i too wanted to implement support for reading the ogg tag info (Artist, Title, comments, etc) like i do with mp3 files. So i took the samplesource vorbisfile.c and pasted and copied some basic stuff to see if i can get that to work. To my suprise it does not work, only a crash when calling the function ov_open(...). Below is the code snippet i use, everything else works fine, its the ov_open function that crashes. May you can give me any help?
(Oh... and hit the carriage return now and then, eh? ;-)
> --------
> if( lstrcmpi( Filename+lstrlen(Filename)-3, "ogg" ) == 0 )
> {
> OggVorbis_File vf;
>
> file = fopen( Filename, "rb" );
> if( !file ) return;
>
> memset(&vf, 0, sizeof(vf));
> if( ov_open( file, &vf, NULL, 0 ) < 0 ) // CRASH
> {
> Warning( "Input does not appear to be an Ogg bitstream." );
> return;
> }
>
> // Close:
> ov_clear(&vf); // xmms says it does the fclose() itsself.
> //fclose(file);
> return;
> }
>
Monty
--- >8 ----
List archives: http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'vorbis-dev-request at xiph.org'
containing only the word 'unsubscribe' in the body. No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.
More information about the Vorbis-dev
mailing list