Commit b7331f9b authored by Shivakumar GN's avatar Shivakumar GN Committed by Shenghou Ma

codereview: use subprocess.call() instead of os.spawnvp() for portability

Fixes #4121.

R=golang-dev, minux.ma, dave, r
CC=golang-dev
https://golang.org/cl/6555049
parent 60a6ae8c
......@@ -1772,7 +1772,7 @@ def gofmt(ui, repo, *pats, **opts):
cmd = ["gofmt", "-l"]
if not opts["list"]:
cmd += ["-w"]
if os.spawnvp(os.P_WAIT, "gofmt", cmd + files) != 0:
if subprocess.call(cmd + files) != 0:
raise hg_util.Abort("gofmt did not exit cleanly")
except hg_error.Abort, e:
raise
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment