summaryrefslogtreecommitdiff
path: root/src/Fl_File_Chooser2.cxx
diff options
context:
space:
mode:
authorMatthias Melcher <git@matthiasm.com>2018-12-27 13:05:35 +0100
committerMatthias Melcher <git@matthiasm.com>2018-12-27 13:05:35 +0100
commit75eefbcd42e7117de110f1d77e892912a24fc0a4 (patch)
tree65063dcd8a49a0c61fa1995acc3f91f9aaf902af /src/Fl_File_Chooser2.cxx
parent5c7118f8d9a4a89742c33d411e5f207b9108b32e (diff)
Fixing some minor lint, found by Pavel Shlyak using PVS studio
Diffstat (limited to 'src/Fl_File_Chooser2.cxx')
-rw-r--r--src/Fl_File_Chooser2.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Fl_File_Chooser2.cxx b/src/Fl_File_Chooser2.cxx
index 57226056d..426dbfd51 100644
--- a/src/Fl_File_Chooser2.cxx
+++ b/src/Fl_File_Chooser2.cxx
@@ -432,7 +432,8 @@ Fl_File_Chooser::count() {
void
Fl_File_Chooser::directory(const char *d)// I - Directory to change to
{
- char *dirptr; // Pointer into directory
+ char *dirptr; // Pointer into directory
+ char fixpath[FL_PATH_MAX]; // Path with slashes converted
// printf("Fl_File_Chooser::directory(\"%s\")\n", d == NULL ? "(null)" : d);
@@ -444,7 +445,6 @@ Fl_File_Chooser::directory(const char *d)// I - Directory to change to
if (Fl::system_driver()->backslash_as_slash()) {
// See if the filename contains backslashes...
char *slash; // Pointer to slashes
- char fixpath[FL_PATH_MAX]; // Path with slashes converted
if (strchr(d, '\\')) {
// Convert backslashes to slashes...
strlcpy(fixpath, d, sizeof(fixpath));