Skip to content

Commit

Permalink
ASAN fix GetDOSBoxXPath
Browse files Browse the repository at this point in the history
  • Loading branch information
caiiiycuk committed Nov 26, 2023
1 parent 7d0c5a1 commit 74d0136
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion native/jsdos/dosbox-x/jsdos-x-main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -393,8 +393,11 @@ extern int aspect_ratio_x, aspect_ratio_y;
extern bool sync_time, loadlang, addovl;
extern bool bootguest, bootfast, bootvm;

std::string dosboxpath="";
std::string GetDOSBoxXPath(bool withexe=false) {
#ifdef JSDOS
return withexe ? "/home/web_user/dosbox-x" : "/home/web_user";
#else
std::string dosboxpath="";
std::string full;
#if defined(HX_DOS) || defined(__MINGW32__) && !defined(__MINGW64_VERSION_MAJOR)
char exepath[MAX_PATH];
Expand All @@ -418,6 +421,7 @@ std::string GetDOSBoxXPath(bool withexe=false) {
dosboxpath="";
}
return dosboxpath;
#endif
}

#if defined(WIN32) && !defined(C_SDL2)
Expand Down

0 comments on commit 74d0136

Please sign in to comment.