Fix Exception in main.cpp
If Project64 is run from C:\Project64, we get an exception in main.cpp. This fixes that bug.
This commit is contained in:
parent
0fe208fbe3
commit
8e75fed8d9
|
@ -587,6 +587,11 @@ void CPath::SetComponents(const char * lpszDrive, const char * lpszDirectory, co
|
|||
char buff_fullname[MAX_PATH];
|
||||
|
||||
memset(buff_fullname, 0, sizeof(buff_fullname));
|
||||
if (lpszDirectory == NULL || strlen(lpszDirectory) == 0)
|
||||
{
|
||||
static char empty_dir[] = { DIRECTORY_DELIMITER, '\0' };
|
||||
lpszDirectory = empty_dir;
|
||||
}
|
||||
|
||||
_makepath(buff_fullname, lpszDrive, lpszDirectory, lpszName, lpszExtension);
|
||||
m_strPath.erase();
|
||||
|
|
Loading…
Reference in New Issue