Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: Missing EOF flag (Read 3575 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Missing EOF flag

I'm having problems with some vorbis files that crash my Trekstor Vibez player after being played. Trekstor support told me this would be due to missing end-of-file flags and advised me to use another encoder. Now I don't remember whom I got the files from and re-encoding already lossy files sounds like a nasty plan to me and shouldn't be necessary anyway as xmms and all other software players I tried had no problems. Do you know of any tool that adds the missing flags, preferably for Linux?

Many thanks in advance!

Missing EOF flag

Reply #1
Figured it out myself. Had I searched for "EOS" instead of "EOF" I would even have found a thread in this forum. Not a very helpful one unfortunately but I got around that problem, too: There's a tiny example tool in liboggz called fix-eos.c. It probably won't be in your oggz packet so download the library and do a ./configure && make. Then go to src/examples and run ./fix-eos input.ogg output.ogg. Voila.

Missing EOF flag

Reply #2
I wrote a little script that might prove helpful to you, too. It's a quick and dirty hack and should be treated as such. Particularly DON'T RUN IT ON YOUR WHOLE MUSIC COLLECTION (and if you must, do a backup, please!). I use it on the files on my vibez and that's it. That said, create a file with the pathnames of all the .ogg files you want to process. (i.e. find /path/to/vibez -iname '*.ogg' > ogglist). You don't need to seperate the bad files from the good ones, the script does this for you. You need to seperate the ogg files from all other ones though as the script doesn't do this and the outcome is probably fatal to your non-ogg files. Then put a file containing the following code into the same directory as the fix-eos binary (or change the path in the script) and make it executable (chmod +x fixall.sh or whatever you called it).

Code: [Select]
#!/bin/bash
cd `dirname $0`
tmpogg=`mktemp`
while read oggfile
do
ogginfo -q "$oggfile" || (mv "$oggfile" $tmpogg && echo "running fix-eos on $oggfile" && ./fix-eos $tmpogg "$oggfile" && rm -f $tmpogg)
done


Finally pipe your list into the script (cat ogglist | ./fixall.sh) and carelessly enjoy Ogg/Vorbis files on your vibez :)

Any improvements (shouldn't be that hard) welcome. For example if you find out how to install fix-eos in some decent place like /usr/local/bin, let me know. Don't know what this .lib stuff is about.