]> Cypherpunks repositories - gostls13.git/commitdiff
os/exec: remove unnecessary fmt.Sprintf call
authorguoguangwu <guoguangwug@gmail.com>
Fri, 1 Mar 2024 10:11:56 +0000 (10:11 +0000)
committerGopher Robot <gobot@golang.org>
Mon, 4 Mar 2024 15:53:53 +0000 (15:53 +0000)
Change-Id: Ic0ac97a15dadd756d727fd8abe23359b0347af19
GitHub-Last-Rev: a96a3f5fe7fbfb41f38acadab3c03c4a76c89b78
GitHub-Pull-Request: golang/go#66052
Reviewed-on: https://go-review.googlesource.com/c/go/+/568317
Reviewed-by: Bryan Mills <bcmills@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Reviewed-by: Jorropo <jorropo.pgm@gmail.com>
Auto-Submit: Ian Lance Taylor <iant@google.com>

src/os/exec/exec_test.go

index 0f9c71ab57a6e9018d2f4e0e0f60375eab63c553..c4b89e019924d29999c1aad47018ccbad26c7bf1 100644 (file)
@@ -304,7 +304,7 @@ func cmdExit(args ...string) {
 }
 
 func cmdDescribeFiles(args ...string) {
-       f := os.NewFile(3, fmt.Sprintf("fd3"))
+       f := os.NewFile(3, "fd3")
        ln, err := net.FileListener(f)
        if err == nil {
                fmt.Printf("fd3: listener %s\n", ln.Addr())