aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/malloc.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/runtime/malloc.go')
-rw-r--r--src/runtime/malloc.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/runtime/malloc.go b/src/runtime/malloc.go
index 5f1e2f64c0..ee4728c9a5 100644
--- a/src/runtime/malloc.go
+++ b/src/runtime/malloc.go
@@ -793,7 +793,7 @@ func newarray(typ *_type, n uintptr) unsafe.Pointer {
flags |= flagNoScan
}
if int(n) < 0 || (typ.size > 0 && n > _MaxMem/typ.size) {
- panic("runtime: allocation size out of range")
+ panic(plainError("runtime: allocation size out of range"))
}
return mallocgc(typ.size*n, typ, flags)
}