summary refs log tree commit diff stats
path: root/lib
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2014-02-14 15:46:30 +0100
committerAraq <rumpf_a@web.de>2014-02-14 15:46:30 +0100
commit09c8a5134826ca53e145313c27cb4084528179a5 (patch)
treec6e40075866b41cf076bc6261ca2925b15ca5389 /lib
parente210b049e99b3a42933f099f7fe0f834bcba1cf3 (diff)
downloadNim-09c8a5134826ca53e145313c27cb4084528179a5.tar.gz
bugfix: 'system' on windows is sane
Diffstat (limited to 'lib')
-rw-r--r--lib/pure/os.nim5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/pure/os.nim b/lib/pure/os.nim
index bb70f28b6..75adb1174 100644
--- a/lib/pure/os.nim
+++ b/lib/pure/os.nim
@@ -1037,7 +1037,10 @@ proc execShellCmd*(command: string): int {.rtl, extern: "nos$1",
   ## the process has finished. To execute a program without having a
   ## shell involved, use the `execProcess` proc of the `osproc`
   ## module.
-  result = c_system(command) shr 8
+  when defined(windows):
+    result = c_system(command)
+  else:
+    result = c_system(command) shr 8
 
 # Environment handling cannot be put into RTL, because the ``envPairs``
 # iterator depends on ``environment``.