Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
text/scanner: guard against installed IsIdentRune that accepts EOF
IsIdentRune may be installed by a client of the scanner. If the installed function accepts EOF as a valid identifier rune, Scan calls may not terminate. Check for EOF when a user-defined IsIdentRune is used. Fixes #50909. Change-Id: Ib104b03ee59e2d58faa71f227c3b51ba424f7f61 Reviewed-on: https://go-review.googlesource.com/c/go/+/393254 Trust: Robert Griesemer <[email protected]> Run-TryBot: Robert Griesemer <[email protected]> TryBot-Result: Gopher Robot <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]>
- Loading branch information