diff options
| author | Matthias Melcher <github@matthiasm.com> | 2022-06-11 12:34:47 +0200 |
|---|---|---|
| committer | Matthias Melcher <github@matthiasm.com> | 2022-06-11 12:34:47 +0200 |
| commit | 9c89a7f320ff1be3bf7dd8f677391e95d8814744 (patch) | |
| tree | 84181cafd7ed47f4e6767e39ca6f64e91f23d1cb /src/filename_absolute.cxx | |
| parent | bcbdf5546f53afdc0e3a4bb7458eb863783e76fd (diff) | |
Handling trailing ".." in fl_filename_absolute.
Diffstat (limited to 'src/filename_absolute.cxx')
| -rw-r--r-- | src/filename_absolute.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/filename_absolute.cxx b/src/filename_absolute.cxx index 4e4e8ff56..653217a0d 100644 --- a/src/filename_absolute.cxx +++ b/src/filename_absolute.cxx @@ -72,7 +72,7 @@ int Fl_System_Driver::filename_absolute(char *to, int tolen, const char *from) { if (isdirsep(*(a-1))) a--; /* remove intermediate . and .. names: */ while (*start == '.') { - if (start[1]=='.' && isdirsep(start[2])) { + if (start[1]=='.' && (isdirsep(start[2]) || start[2]==0) ) { char *b; for (b = a-1; b >= temp && !isdirsep(*b); b--) {/*empty*/} if (b < temp) break; |
