diff options
Diffstat (limited to 'lib/pure/os.nim')
-rwxr-xr-x | lib/pure/os.nim | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/pure/os.nim b/lib/pure/os.nim index 65f58e6d3..943caec7e 100755 --- a/lib/pure/os.nim +++ b/lib/pure/os.nim @@ -580,7 +580,7 @@ proc expandFilename*(filename: string): string {.rtl, extern: "nos$1".} = var L = GetFullPathNameA(filename, bufsize, result, unused) if L <= 0'i32 or L >= bufsize: OSError() setLen(result, L) - elif defined(macosx): + elif defined(macosx) or defined(bsd): # On Mac OS X 10.5, realpath does not allocate the buffer on its own var pathBuffer: cstring = newString(pathMax) var resultBuffer = realpath(filename, pathBuffer) @@ -1377,7 +1377,7 @@ proc getAppFilename*(): string {.rtl, extern: "nos$1".} = result = getApplAux("/proc/" & $getpid() & "/path/a.out") elif defined(bsd): result = getApplAux("/proc/" & $getpid() & "/file") - elif defined(macosx) or defined(bsd): + elif defined(macosx): var size: int32 getExecPath1(nil, size) result = newString(int(size)) |