]> Cypherpunks repositories - gostls13.git/commit
fmt: fix handling of %% verb in Scanf
authorRob Pike <r@golang.org>
Thu, 24 Oct 2019 07:22:43 +0000 (18:22 +1100)
committerRob Pike <r@golang.org>
Fri, 25 Oct 2019 04:15:59 +0000 (04:15 +0000)
commit4f70c151db6a2f169058a193232263733aa3947e
treea56e1fae61d5b029846374d447a346ea3104419d
parent8f30d25168cae6380d9ef50528063716261356c4
fmt: fix handling of %% verb in Scanf

There were a couple of bugs, including not requiring a percent and
returning the wrong error for a bad format containing %%.

Both are addressed by fixing the first.

Fixes #34180.

Change-Id: If96c0c0258bcb95eec49871437d719cb9d399d9b
Reviewed-on: https://go-review.googlesource.com/c/go/+/202879
Run-TryBot: Emmanuel Odeke <emm.odeke@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
src/fmt/scan.go
src/fmt/scan_test.go