diff options
-rwxr-xr-x | koch.nim | 10 | ||||
-rwxr-xr-x | lib/pure/os.nim | 3 | ||||
-rwxr-xr-x | lib/pure/osproc.nim | 2 |
3 files changed, 8 insertions, 7 deletions
diff --git a/koch.nim b/koch.nim index b5d407a0f..d3caa27df 100755 --- a/koch.nim +++ b/koch.nim @@ -180,11 +180,11 @@ proc tests(args: string) = # we compile the tester with taintMode:on to have a basic # taint mode test :-) exec("nimrod cc --taintMode:on tests/tester") - exec("tests/tester reject") - exec("tests/tester compile") - exec("tests/tester examples") - exec("tests/tester run") - exec("tests/tester merge") + exec(getCurrentDir() / "tests/tester".exe & " reject") + exec(getCurrentDir() / "tests/tester".exe & " compile") + exec(getCurrentDir() / "tests/tester".exe & " examples") + exec(getCurrentDir() / "tests/tester".exe & " run") + exec(getCurrentDir() / "tests/tester".exe & " merge") proc showHelp() = quit(HelpText % [NimrodVersion & repeatChar(44-len(NimrodVersion)), diff --git a/lib/pure/os.nim b/lib/pure/os.nim index 2edf999d3..c7e3dccb4 100755 --- a/lib/pure/os.nim +++ b/lib/pure/os.nim @@ -868,7 +868,8 @@ iterator walkDirRec*(dir: string, filter={pcFile, pcDir}): string = proc rawRemoveDir(dir: string) = when defined(windows): - if RemoveDirectoryA(dir) == 0'i32 and GetLastError() != 3'i32: OSError() + if RemoveDirectoryA(dir) != 0'i32 and GetLastError() != 3'i32 and + GetLastError() != 18'i32: OSError() else: if rmdir(dir) != 0'i32 and errno != ENOENT: OSError() diff --git a/lib/pure/osproc.nim b/lib/pure/osproc.nim index 03c3def4d..e01953e85 100755 --- a/lib/pure/osproc.nim +++ b/lib/pure/osproc.nim @@ -131,7 +131,7 @@ proc countProcessors*(): int {.rtl, extern: "nosp$1".} = ## Returns 0 if it cannot be detected. when defined(windows): var x = getenv("NUMBER_OF_PROCESSORS") - if x.len > 0: result = parseInt(x) + if x.len > 0: result = parseInt(x.string) elif defined(macosx) or defined(bsd): var mib: array[0..3, cint] |