Fix undefined macro check in linux.c

This commit is contained in:
Michał Janiszewski 2017-01-02 22:34:40 +01:00
parent cbef2c8a29
commit 8cb1460ca8
1 changed files with 1 additions and 1 deletions

View File

@ -62,7 +62,7 @@ void platform_get_exe_path(utf8 *outPath, size_t outSize)
log_fatal("failed to read /proc/self/exe");
}
exePath[bytesRead - 1] = '\0';
#elif __FREEBSD__
#elif defined(__FREEBSD__)
size_t exeLen = sizeof(exePath);
const int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_PATHNAME, -1 };
if (sysctl(mib, 4, exePath, &exeLen, NULL, 0) == -1) {