]> Cypherpunks repositories - gostls13.git/commitdiff
syscall: fix inverse checking of result code on windows.
authorYasuhiro Matsumoto <mattn.jp@gmail.com>
Wed, 16 Feb 2011 05:07:04 +0000 (16:07 +1100)
committerAlex Brainman <alex.brainman@gmail.com>
Wed, 16 Feb 2011 05:07:04 +0000 (16:07 +1100)
R=golang-dev, brainman, rsc
CC=golang-dev
https://golang.org/cl/4179049

src/pkg/syscall/exec_windows.go

index 7256c3ae3fc4d88d9e26082a5c3e7f7c6dcd17ee..73c3c8624d55d26b270ba1520575860cc96ff823 100644 (file)
@@ -185,7 +185,7 @@ func StartProcess(argv0 string, argv []string, envv []string, dir string, fd []i
                startupInfo,
                processInfo)
 
-       if err != 0 {
+       if err == 0 {
                pid = int(processInfo.ProcessId)
                handle = int(processInfo.Process)
                CloseHandle(processInfo.Thread)