Skip to content

Commit

Permalink
cast appropriately to build on Mac (SDL NFD)
Browse files Browse the repository at this point in the history
  • Loading branch information
bazz1tv committed Apr 1, 2022
1 parent f1574b1 commit 7ad398f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pc/shared/SdlNfd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ nfdresult_t SdlNfd::get_file_handle(const char *rw, const char *filter_list/*=NU
if (strstr(outPath, extensionBuf) == NULL)
{
DEBUGLOG("File extension is NOT present\n");
finalPath = malloc (strlen(outPath) + 1 + strlen(extensionBuf) + 1); // the plus 1's are the '.' and the null char
finalPath = (char *) malloc (strlen(outPath) + 1 + strlen(extensionBuf) + 1); // the plus 1's are the '.' and the null char
// append that extension to a new string
strcpy(finalPath, outPath);
strcat(finalPath, extensionBuf);
Expand Down

0 comments on commit 7ad398f

Please sign in to comment.