Skip to content

Commit

Permalink
Add conversion for string.
Browse files Browse the repository at this point in the history
  • Loading branch information
jrincayc committed Dec 27, 2023
1 parent 9d2aacf commit 1943581
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion wxMain.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ extern "C" int wxUnget_c(int c, FILE * f) {
extern "C" void getExecutableDir(char * path, int maxlen) {
wxString executable = wxStandardPaths::Get().GetExecutablePath();
wxString executable_dir = wxFileName(executable).GetPath();
strncpy(path, executable_dir, maxlen);
strncpy(path, (const char*)executable_dir.mb_str(wxConvUTF8), maxlen);
path[maxlen - 1] = '\0';
}

Expand Down

0 comments on commit 1943581

Please sign in to comment.