mirror of
https://github.com/golang/go
synced 2024-09-24 17:10:13 -06:00
fix range on invalid utf8 bug
R=r DELTA=42 (21 added, 20 deleted, 1 changed) OCL=34328 CL=34333
This commit is contained in:
parent
cf336b10df
commit
a18208fb60
@ -161,8 +161,9 @@ bad:
|
||||
*rune = Bad;
|
||||
return 1;
|
||||
badlen:
|
||||
// was return 0, but return 1 is more convenient for the runtime.
|
||||
*rune = Bad;
|
||||
return 0;
|
||||
return 1;
|
||||
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user