Skip to content
Snippets Groups Projects
Commit be622038 authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

viewfile() now uses case-corrected file path

Sometimes files uploaded may have the wrong case in the filebase (a different
unresolved issue), but for instances where that has happened, make those files
viewable in sbbs. This really only impacts target OSes with case-sensitive
file systems (e.g. *nix).
parent 872a5485
No related branches found
No related tags found
No related merge requests found
......@@ -86,12 +86,14 @@ int sbbs_t::viewfile(file_t* f, bool ext)
/*****************************************************************************/
/*****************************************************************************/
bool sbbs_t::viewfile(const char* path)
bool sbbs_t::viewfile(const char* inpath)
{
char path[MAX_PATH + 1];
char viewcmd[256];
int i;
if(!fexist(path)) {
SAFECOPY(path, inpath);
if(!fexistcase(path)) {
bputs(text[FileNotFound]);
return false;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment