]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/link: remove superfluous check in TestIssue34788Android386TLSSequence
authorTobias Klauser <tklauser@distanz.ch>
Tue, 25 Aug 2020 13:19:50 +0000 (15:19 +0200)
committerTobias Klauser <tobias.klauser@gmail.com>
Tue, 25 Aug 2020 14:47:39 +0000 (14:47 +0000)
err != nil is already checked in the if condition one line above.

Change-Id: If36cdb41016f7be98a65be0a7211d85cd6017f87
Reviewed-on: https://go-review.googlesource.com/c/go/+/250477
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
src/cmd/link/link_test.go

index 3b5efdf7a3c9b4cf94f7871c38694788fe9f2f7e..72ff01c9320edfe5526ebfe8b54f74a713b20240 100644 (file)
@@ -455,9 +455,7 @@ func TestIssue34788Android386TLSSequence(t *testing.T) {
        cmd := exec.Command(testenv.GoToolPath(t), "tool", "compile", "-o", obj, src)
        cmd.Env = append(os.Environ(), "GOARCH=386", "GOOS=android")
        if out, err := cmd.CombinedOutput(); err != nil {
-               if err != nil {
-                       t.Fatalf("failed to compile blah.go: %v, output: %s\n", err, out)
-               }
+               t.Fatalf("failed to compile blah.go: %v, output: %s\n", err, out)
        }
 
        // Run objdump on the resulting object.