summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
authorWilliam Wilgus <wilgus.william@gmail.com>2023-09-23 11:10:21 -0400
committerWilliam Wilgus <wilgus.william@gmail.com>2023-09-23 11:19:59 -0400
commit62db16c82c27e2ca6895b6c50fdc9d3b30be4702 (patch)
tree4897a7bb55f736bd10cf926afdfa17426c12c15b /apps
parentfcc82dfdca470e49d864da9af4fa9573ad6e54fe (diff)
downloadrockbox-62db16c82c27e2ca6895b6c50fdc9d3b30be4702.tar.gz
rockbox-62db16c82c27e2ca6895b6c50fdc9d3b30be4702.zip
[BugFix] bookmark.c root_dir bookmark
in some calls to generate_bookmark_file_name() len gets specified in order to not NULL terminate the buffer string unfortunately, I missed the root_dir case in g#4839 Change-Id: I24d1360bbe72e6a1b2ed3332ff5854d039d58ca5
Diffstat (limited to 'apps')
-rw-r--r--apps/bookmark.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/bookmark.c b/apps/bookmark.c
index 68c10b36e7..0b468bdb76 100644
--- a/apps/bookmark.c
+++ b/apps/bookmark.c
@@ -380,7 +380,7 @@ static bool generate_bookmark_file_name(char *filenamebuf,
380{ 380{
381 /* if this is a root dir MP3, rename the bookmark file root_dir.bmark */ 381 /* if this is a root dir MP3, rename the bookmark file root_dir.bmark */
382 /* otherwise, name it based on the bmarknamein variable */ 382 /* otherwise, name it based on the bmarknamein variable */
383 if (!strcmp("/", bmarknamein)) 383 if (!strncmp("/", bmarknamein, bmarknamelen))
384 strmemccpy(filenamebuf, "/root_dir.bmark", filenamebufsz); 384 strmemccpy(filenamebuf, "/root_dir.bmark", filenamebufsz);
385 else 385 else
386 { 386 {