1
0
mirror of https://github.com/golang/go synced 2024-11-21 20:14:52 -07:00

strconv.Unquote could wrongly return a nil error on error.

R=rsc, gri
CC=golang-dev
https://golang.org/cl/773041
This commit is contained in:
Roger Peppe 2010-03-29 10:09:29 -07:00 committed by Robert Griesemer
parent 9ba5ec53ad
commit a48115bf2e

View File

@ -239,7 +239,7 @@ func Unquote(s string) (t string, err os.Error) {
return s, nil
}
if quote != '"' && quote != '\'' {
return "", err
return "", os.EINVAL
}
var buf bytes.Buffer