mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-05 01:20:42 +00:00
Apple remove allocPath from GetExecutableFilename
allocPath was allocated but never used
This commit is contained in:
committed by
Baldur Karlsson
parent
ed954cea4d
commit
6b6a720c08
@@ -91,8 +91,6 @@ void GetExecutableFilename(rdcstr &selfName)
|
||||
else
|
||||
{
|
||||
pathSize++;
|
||||
char *allocPath = new char[pathSize];
|
||||
memset(allocPath, 0, pathSize);
|
||||
if(_NSGetExecutablePath(path, &pathSize) == 0)
|
||||
{
|
||||
selfName = rdcstr(path);
|
||||
@@ -101,10 +99,8 @@ void GetExecutableFilename(rdcstr &selfName)
|
||||
{
|
||||
selfName = "/unknown/unknown";
|
||||
RDCERR("Can't get executable name");
|
||||
delete[] allocPath;
|
||||
return; // don't try and readlink this
|
||||
}
|
||||
delete[] allocPath;
|
||||
}
|
||||
|
||||
memset(path, 0, sizeof(path));
|
||||
|
||||
Reference in New Issue
Block a user