]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/go/internal/script: log the stop message instead of the state when stopping
authorBryan C. Mills <bcmills@google.com>
Mon, 24 Apr 2023 17:52:28 +0000 (13:52 -0400)
committerGopher Robot <gobot@golang.org>
Tue, 2 May 2023 16:06:05 +0000 (16:06 +0000)
Change-Id: I3c887b5f3716e78dfffad6869f986c4381fae3e7
Reviewed-on: https://go-review.googlesource.com/c/go/+/488235
Run-TryBot: Bryan Mills <bcmills@google.com>
Reviewed-by: Michael Matloob <matloob@golang.org>
Auto-Submit: Bryan Mills <bcmills@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>

src/cmd/go/internal/script/engine.go

index dfce75552223db2f9f857b7a5cbc7646b9e0e6a5..43054a279b853f4f4550e3cbd47a0973d9bf036c 100644 (file)
@@ -295,7 +295,7 @@ func (e *Engine) Execute(s *State, file string, script *bufio.Reader, log io.Wri
                                // Since the 'stop' command halts execution of the entire script,
                                // log its message separately from the section in which it appears.
                                err = endSection(true)
-                               s.Logf("%v\n", s)
+                               s.Logf("%v\n", stop)
                                if err == nil {
                                        return nil
                                }