Rockbox.org home
release
dev builds
extras
themes manual
wiki
device status forums
mailing lists
IRC bugs
patches
dev guide
translations



Rockbox mail archive

Subject: RE: Possible Filename Buffer Overrun

RE: Possible Filename Buffer Overrun

From: Lee Marlow <lmarlow_at_yahoo.com>
Date: Wed, 10 Jul 2002 08:45:08 -0600

This happened to me as well. What version of Rockbox are you running?
Linus committed a fix on 7/3 that should have fixed it.

Lee
lmarlow_at_yahoo.com
irc: mecraw

-----Original Message-----
From: owner-rockbox_at_cool.haxx.se [mailto:owner-rockbox_at_cool.haxx.se] On
Behalf Of Stuart Tedford
Sent: Wednesday, July 10, 2002 2:46 AM
To: rockbox_at_cool.haxx.se
Subject: Possible Filename Buffer Overrun

I have done some more investigation into this bug. The scrolling
filename
on the top line of the screen when playing a file eventually shows
unrecognised characters (usually displayed as '?') when I play a file
with a
long file name such as:

"/MP3/MP3_Old/Smashing Pumpkins - The Aeroplane Flies High - Thirty
Three/03_The Aeroplane Flies High (Turns Left, Looks Right).mp3"

To save you counting, this filename and path is 130 chars long.

The scrolling display shows the filename across the screen until the
very
last char (the '3' in ".....mp3") ie 129 chars, where it begins to
display
'?' chars for a while with the odd '/' and other weird chars thrown in
until
recovering back to the start again and repeating the whole process. I
presume the pointer that the scroller is reading from eventually finds a
NULL somewhere off the end of the buffer.

I haven't looked at the code, but what I think is happening is that the
file
name buffer (rather than the scroller code) is at fault, and is not
large
enough to store a filename of this length - and so is not appending a
null
to the buffer - or worse - is writing past the end of the buffer. In
my
experience, a filename buffer should be 256 chars - thanks to windoze.
If
this is not acceptable then the file name should be truncated properly.

Does anyone else have long filenames - or is it just me?

Stu.
Received on 2002-07-10

Page template was last modified "Tue Sep 7 00:00:02 2021" The Rockbox Crew -- Privacy Policy