mirror of
https://github.com/hanzoai/expr.git
synced 2026-09-24 16:58:58 +00:00
Fix if
This commit is contained in:
@@ -32,7 +32,7 @@ func unescape(value string) (string, error) {
|
||||
// The string contains escape characters.
|
||||
// The following logic is adapted from `strconv/quote.go`
|
||||
var runeTmp [utf8.UTFMax]byte
|
||||
if n >= 2/3*math.MaxInt {
|
||||
if n >= 2*math.MaxInt/3 {
|
||||
return "", fmt.Errorf("too large string")
|
||||
}
|
||||
buf := make([]byte, 0, 3*n/2)
|
||||
|
||||
Reference in New Issue
Block a user