1
0
mirror of https://github.com/golang/go synced 2024-10-02 12:28:33 -06:00
go/src
Austin Clements 97dc591534 runtime: avoid stat underflow crash
If the area returned by sysReserve in mheap.sysAlloc is outside the
usable arena, we sysFree it. We pass a fake stat pointer to sysFree
because we haven't added the allocation to any stat at that point.
However, we pass a 0 stat, so sysFree panics when it decrements the
stat because the fake stat underflows.

Fix this by setting the fake stat to the allocation size.

Updates #13143 (this is a prerequisite to fixing that bug).

Change-Id: I61a6c9be19ac1c95863cf6a8435e19790c8bfc9a
Reviewed-on: https://go-review.googlesource.com/16926
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2015-11-16 17:32:29 +00:00
..
archive archive/tar: make output deterministic 2015-11-13 02:02:32 +00:00
bufio bufio: fix scanning with a final empty token. 2015-09-25 21:46:13 +00:00
builtin
bytes
cmd cmd/dist, cmd/go: run testshared on arm64 2015-11-15 23:41:28 +00:00
compress compress/gzip: specify when Reader.Header is valid 2015-11-13 09:16:53 +00:00
container
crypto crypto/tls: add TLS_RSA_WITH_AES_128_GCM_SHA256 and TLS_RSA_WITH_AES_256_GCM_SHA384 cipher suites 2015-11-15 20:59:11 +00:00
database/sql database/sql: use RWMutex for driver registration 2015-10-23 04:33:50 +00:00
debug debug/elf: added MIPS ELF relocations 2015-11-12 04:50:32 +00:00
encoding encoding/json: use reflect.SetBytes when decoding bytes 2015-11-14 23:41:46 +00:00
errors
expvar
flag
fmt fmt: Add support for capital '%X' format verb for scanning 2015-10-20 01:08:54 +00:00
go runtime/internal/atomic: delete arch1_*.go files 2015-11-12 17:37:22 +00:00
hash hash/crc32: added mips64{,le} build tags 2015-11-12 04:50:43 +00:00
html html/template, encoding/asn1: fix test errors 2015-11-10 00:30:41 +00:00
image image: add NYCbCrA types. 2015-10-11 11:07:25 +00:00
index/suffixarray
internal internal/syscall/unix: added support for linux/mips64{,le} 2015-11-12 04:51:12 +00:00
io io: simplify documentation for ByteReader 2015-10-06 02:21:29 +00:00
log log/syslog: disable unix/unixgram tests on android 2015-10-21 17:56:51 +00:00
math math/rand: add a comment for the i=0 iteration 2015-11-15 08:21:29 +00:00
mime mime: Remove an allocation in word decoding. 2015-10-18 17:31:52 +00:00
net net/rpc: verify that embedding works with changed semantics 2015-11-13 19:47:35 +00:00
os os: add document for ErrInvalid 2015-11-13 01:09:10 +00:00
path path/filepath: in Rel use case-insensitive comparison on Windows 2015-11-12 19:58:37 +00:00
reflect reflect: added support for mips64{,le} 2015-11-12 04:50:18 +00:00
regexp regexp: fix slice bounds out of range panics 2015-10-23 03:30:25 +00:00
runtime runtime: avoid stat underflow crash 2015-11-16 17:32:29 +00:00
sort
strconv strconv: slightly simplified roundShortest; better comments 2015-09-23 21:14:29 +00:00
strings strings: add asm version of Index() for short strings on amd64 2015-11-03 16:04:28 +00:00
sync sync/atomic: added support for mips64{,le} 2015-11-12 04:49:45 +00:00
syscall syscall: added support for linux/mips64{,le} 2015-11-12 04:49:34 +00:00
testing testing: only call flag.Parse if it has not been called before 2015-11-12 19:48:06 +00:00
text text/template: remove redundant indirect 2015-10-28 02:51:40 +00:00
time
unicode unicode/utf8: removed uses of ranging over string 2015-11-16 11:29:13 +00:00
unsafe
vendor/golang.org/x/net/http2/hpack net/http: update copy of http2 2015-10-21 00:28:55 +00:00
all.bash
all.bat
all.rc
androidtest.bash androidtest.bash: set GOARM=7 2015-10-26 15:20:02 +00:00
bootstrap.bash
buildall.bash
clean.bash
clean.bat
clean.rc
iostest.bash
make.bash
make.bat
Make.dist
make.rc
nacltest.bash
race.bash
race.bat
run.bash
run.bat
run.rc