summaryrefslogtreecommitdiff
path: root/win32.c
diff options
context:
space:
mode:
Diffstat (limited to 'win32.c')
-rw-r--r--win32.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/win32.c b/win32.c
index 5188065ea..f1bc33da5 100644
--- a/win32.c
+++ b/win32.c
@@ -631,7 +631,7 @@ static HANDLE MyFindFirstFile(const char *path, const char *file, WIN32_FIND_DAT
HANDLE h;
char paths[MAX_PATH];
- sprintf(paths, "%s\\%s", path, file);
+ snprintf(paths, sizeof(paths), "%s\\%s", path, file);
h = FindFirstFile(paths, fd);
SetErrorMode(sem); // restore previous setting
@@ -900,7 +900,7 @@ char *FiosBrowseTo(const FiosItem *item)
switch (item->type) {
case FIOS_TYPE_DRIVE:
- sprintf(path, "%c:\\", item->title[0]);
+ sprintf(path, "%c:", item->title[0]);
break;
case FIOS_TYPE_PARENT: