ABI fixes for OSX/BSD; fixes #6860 (#11666)

This commit is contained in:
Andreas Rumpf 2019-07-06 13:00:29 +02:00 • committed by GitHub
commit 02b9af2f75
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 613 additions and 11 deletions

View file

@ -1492,7 +1492,7 @@ proc setFilePermissions*(filename: string, permissions: set[FilePermission]) {.
if fpOthersWrite in permissions: p = p or S_IWOTH
if fpOthersExec in permissions: p = p or S_IXOTH
if chmod(filename, p) != 0: raiseOSError(osLastError())
if chmod(filename, cast[Mode](p)) != 0: raiseOSError(osLastError())
else:
when useWinUnicode:
wrapUnary(res, getFileAttributesW, filename)