diff options
Diffstat (limited to 'apps/gui/folder_select.c')
-rw-r--r-- | apps/gui/folder_select.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/gui/folder_select.c b/apps/gui/folder_select.c index e324e8649a..cef95e179e 100644 --- a/apps/gui/folder_select.c +++ b/apps/gui/folder_select.c | |||
@@ -516,7 +516,7 @@ static int select_paths(struct folder* root, const char* filenames) | |||
516 | 516 | ||
517 | sstr = lastfnp; | 517 | sstr = lastfnp; |
518 | lastfnp = fnp; | 518 | lastfnp = fnp; |
519 | if (len <= 0 || len > buflen) | 519 | if (len <= 0 || len + 1 >= buflen) |
520 | continue; | 520 | continue; |
521 | strlcpy(buf, sstr, len + 1); | 521 | strlcpy(buf, sstr, len + 1); |
522 | struct child *item = find_from_filename(buf, root); | 522 | struct child *item = find_from_filename(buf, root); |