]>
Cypherpunks repositories - gostls13.git/log
Brad Fitzpatrick [Fri, 21 Sep 2012 19:54:47 +0000 (05:54 +1000)]
[release-branch.go1] A+C: Add Julien Schmidt (Individual CLA)
««« backport
d80f2c4b0445
A+C: Add Julien Schmidt (Individual CLA)
R=golang-dev, iant
CC=golang-dev
https://golang.org/cl/
6459050
»»»
David Symonds [Fri, 21 Sep 2012 19:54:46 +0000 (05:54 +1000)]
[release-branch.go1] A+C: Tobias Columbus (individual CLA)
««« backport
29671078c8aa
A+C: Tobias Columbus (individual CLA)
R=golang-dev, iant
CC=golang-dev
https://golang.org/cl/
6480058
»»»
Adam Langley [Fri, 21 Sep 2012 19:54:46 +0000 (05:54 +1000)]
[release-branch.go1] crypto/tls: return better error message in the case of an SSLv2 handshake.
««« backport
8048fe8f6f4b
crypto/tls: return better error message in the case of an SSLv2 handshake.
Update #3930
Return a better error message in this situation.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
6474055
»»»
Shenghou Ma [Fri, 21 Sep 2012 19:54:45 +0000 (05:54 +1000)]
[release-branch.go1] cmd/6g: fix float32/64->uint64 conversion
««« backport
5972fe3f4418
cmd/6g: fix float32/64->uint64 conversion
CVTSS2SQ's rounding mode is controlled by the RC field of MXCSR;
as we specifically need truncate semantic, we should use CVTTSS2SQ.
Fixes #3804.
R=rsc, r
CC=golang-dev
https://golang.org/cl/
6352079
»»»
Shenghou Ma [Fri, 21 Sep 2012 19:54:45 +0000 (05:54 +1000)]
[release-branch.go1] cmd/ld: set ELF header flags for our Linux/ARM binary
««« backport
1f9e023245d4
cmd/ld: set ELF header flags for our Linux/ARM binary
To make it more compliant.
This won't affect the behavior of running on OABI-only kernels.
R=golang-dev, iant
CC=golang-dev
https://golang.org/cl/
6475044
»»»
Rob Pike [Fri, 21 Sep 2012 19:54:44 +0000 (05:54 +1000)]
[release-branch.go1] C+A: add Carlos Castillo cookieo9@gmail.com (individual CLA)
««« backport
341a5be3052f
C+A: add Carlos Castillo cookieo9@gmail.com (individual CLA)
R=golang-dev, iant
CC=golang-dev
https://golang.org/cl/
6479045
»»»
Rob Pike [Fri, 21 Sep 2012 19:54:44 +0000 (05:54 +1000)]
[release-branch.go1] time: avoid data race in abs
««« backport
b2855a1654b6
time: avoid data race in abs
Fixes #3967.
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/
6460115
»»»
Dave Borowitz [Fri, 21 Sep 2012 19:54:43 +0000 (05:54 +1000)]
[release-branch.go1] net/http: Set TLSClientConfig.ServerName on every HTTP request.
««« backport
8d39afcd18b1
net/http: Set TLSClientConfig.ServerName on every HTTP request.
This makes SNI "just work" for callers using the standard http.Client.
Since we now have a test that depends on the httptest.Server cert, change
the cert to be a CA (keeping all other fields the same).
R=bradfitz
CC=agl, dsymonds, gobot, golang-dev
https://golang.org/cl/
6448154
»»»
Brad Fitzpatrick [Fri, 21 Sep 2012 19:54:43 +0000 (05:54 +1000)]
[release-branch.go1] CONTRIBUTORS: Add Dave Borowitz (Google CLA)
««« backport
52a0395d0e81
CONTRIBUTORS: Add Dave Borowitz (Google CLA)
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
6484046
»»»
Andrew Gerrand [Fri, 21 Sep 2012 19:54:42 +0000 (05:54 +1000)]
[release-branch.go1] A+C: add Joakim Sernbrant
««« backport
dd0a97869e4d
A+C: add Joakim Sernbrant
R=golang-dev, nigeltao
CC=golang-dev
https://golang.org/cl/
6476043
»»»
Dave Cheney [Fri, 21 Sep 2012 19:54:42 +0000 (05:54 +1000)]
[release-branch.go1] net/http: fix misplaced defer and example
««« backport
989f373141cc
net/http: fix misplaced defer and example
Moves the defer (again).
Also, correct the example documentation to match.
R=r, robert.hencke, iant, dsymonds, bradfitz
CC=golang-dev
https://golang.org/cl/
6458158
»»»
Dave Cheney [Fri, 21 Sep 2012 19:54:41 +0000 (05:54 +1000)]
[release-branch.go1] os: fix data race on Process.done
««« backport
4fc1c61c3c2c
os: fix data race on Process.done
Fixes #3969.
R=dvyukov, r, alex.brainman, minux.ma
CC=golang-dev
https://golang.org/cl/
6462081
»»»
Shenghou Ma [Fri, 21 Sep 2012 19:54:41 +0000 (05:54 +1000)]
[release-branch.go1] doc/install: we only need command line tools for Xcode on OS X
««« backport
975bfb6bbac4
doc/install: we only need command line tools for Xcode on OS X
Fixes #3973.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
6464078
»»»
Volker Dobler [Fri, 21 Sep 2012 19:54:40 +0000 (05:54 +1000)]
[release-branch.go1] strconv: consistent parameter names for ParseUint
««« backport
52813bdd69bb
strconv: consistent parameter names for ParseUint
If ParseUint is like ParseInt it should have the same parameter
names, thus rename b to to base as in ParseInt's documentation.
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/
6453152
»»»
Dmitriy Vyukov [Fri, 21 Sep 2012 19:54:40 +0000 (05:54 +1000)]
[release-branch.go1] net/http: reduce mutex contention
««« backport
43568ec5cf55
net/http: reduce mutex contention
benchmark old ns/op new ns/op delta
BenchmarkClientServerParallel 155909 154454 -0.93%
BenchmarkClientServerParallel-2 86012 82986 -3.52%
BenchmarkClientServerParallel-4 70211 55168 -21.43%
BenchmarkClientServerParallel-8 80755 47862 -40.73%
BenchmarkClientServerParallel-12 77753 51478 -33.79%
BenchmarkClientServerParallel-16 77920 50278 -35.47%
The benchmark is https://golang.org/cl/
6441134
The machine is 2 x 4 HT cores (16 HW threads total).
Fixes #3946.
Now contention moves to net.pollServer.AddFD().
R=bradfitz
CC=bradfitz, dave, dsymonds, gobot, golang-dev, remyoudompheng
https://golang.org/cl/
6454142
»»»
Alex Brainman [Fri, 21 Sep 2012 19:54:39 +0000 (05:54 +1000)]
[release-branch.go1] pprof: make it work on windows again
««« backport
7c5f4dad8fae
pprof: make it work on windows again
- pprof is a perl script, so go command should invoke
perl instead of trying to run pprof directly;
- pprof should use "go tool nm" unconditionally on windows,
no one else can extract symbols from Go program;
- pprof should use "go tool nm" instead of "6nm".
Fixes #3879.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
6445082
»»»
Rob Pike [Fri, 21 Sep 2012 19:54:39 +0000 (05:54 +1000)]
[release-branch.go1] all: move defers to after error check to avoid nil indirection
««« backport
8f0c8f604ee0
all: move defers to after error check to avoid nil indirection
Only affects some tests and none seem likely to be problematic, but let's fix them.
Fixes #3971.
R=golang-dev, iant
CC=golang-dev
https://golang.org/cl/
6463060
»»»
Robert Griesemer [Fri, 21 Sep 2012 19:54:38 +0000 (05:54 +1000)]
[release-branch.go1] go_spec: unary + and - are also defined for complex types
««« backport
1546a1ef0102
go_spec: unary + and - are also defined for complex types
R=r, rsc, iant, ken, iant
CC=golang-dev
https://golang.org/cl/
6450150
»»»
Alex Brainman [Fri, 21 Sep 2012 19:54:38 +0000 (05:54 +1000)]
[release-branch.go1] test: change run.go to ignore \r in compiler output (fixes windows build)
««« backport
b86e4ec1dd66
test: change run.go to ignore \r in compiler output (fixes windows build)
R=golang-dev, dave, minux.ma, remyoudompheng
CC=golang-dev
https://golang.org/cl/
6460093
»»»
Daniel Morsing [Fri, 21 Sep 2012 19:54:37 +0000 (05:54 +1000)]
[release-branch.go1] cmd/gc: Don't claim type assertion would help when it wont.
««« backport
b76339cc168a
cmd/gc: Don't claim type assertion would help when it wont.
Fixes #3465.
R=golang-dev, rsc, remyoudompheng, iant
CC=golang-dev
https://golang.org/cl/
6448097
»»»
Ian Lance Taylor [Fri, 21 Sep 2012 19:54:37 +0000 (05:54 +1000)]
[release-branch.go1] A+C: Andrew Lutomirski (individual CLA)
««« backport
8714f560df67
A+C: Andrew Lutomirski (individual CLA)
Wrote code that was the basis for
https://golang.org/cl/
6454046 /
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
6450142
»»»
Dmitriy Vyukov [Fri, 21 Sep 2012 19:54:36 +0000 (05:54 +1000)]
[release-branch.go1] runtime/pprof: fix comments
««« backport
e7e49c318134
runtime/pprof: fix comments
R=golang-dev, iant
CC=golang-dev
https://golang.org/cl/
6460082
»»»
Andrew Gerrand [Fri, 21 Sep 2012 19:54:36 +0000 (05:54 +1000)]
[release-branch.go1] text/template/parse: fix bug handling /*/
Shenghou Ma [Fri, 21 Sep 2012 19:54:36 +0000 (05:54 +1000)]
[release-branch.go1] runtime: use sched_getaffinity for runtime.NumCPU() on Linux
««« backport
3532ab6bf5be
runtime: use sched_getaffinity for runtime.NumCPU() on Linux
Fixes #3921.
R=iant
CC=golang-dev
https://golang.org/cl/
6448132
»»»
Rémy Oudompheng [Fri, 21 Sep 2012 19:54:35 +0000 (05:54 +1000)]
[release-branch.go1] go/build: correct shouldBuild bug reading whole contents of file.
««« backport
307fafbc2d6f
go/build: correct shouldBuild bug reading whole contents of file.
It was caused by bytes.TrimSpace being able to return a nil
slice.
Fixes #3914.
R=golang-dev, r
CC=golang-dev, remy
https://golang.org/cl/
6458091
»»»
Robert Griesemer [Fri, 21 Sep 2012 19:54:35 +0000 (05:54 +1000)]
[release-branch.go1] spec: clarify evaluation order
««« backport
6beada1bf6c2
spec: clarify evaluation order
Fixes #3852.
R=r, rsc, iant, ken
CC=golang-dev
https://golang.org/cl/
6441102
»»»
Charles L. Dorian [Fri, 21 Sep 2012 19:54:34 +0000 (05:54 +1000)]
[release-branch.go1] math: update definition of NaN in assembly language files
««« backport
f26c1758e269
math: update definition of NaN in assembly language files
R=rsc, minux.ma, golang-dev, nigeltao
CC=golang-dev
https://golang.org/cl/
6461047
»»»
Andrew Gerrand [Fri, 21 Sep 2012 19:54:34 +0000 (05:54 +1000)]
[release-branch.go1] doc: add 'Get Started with Go' video, remove some older videos
««« backport
77b1cdceb2b2
doc: add 'Get Started with Go' video, remove some older videos
(I also updated the wiki's GoTalks page with all the latest videos.)
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
6441113
»»»
Andrew Gerrand [Fri, 21 Sep 2012 19:54:33 +0000 (05:54 +1000)]
[release-branch.go1] io: amend ReaderFrom doc as per r's comment
««« backport
5d3aaf0b717e
io: amend ReaderFrom doc as per r's comment
R=r
CC=golang-dev
https://golang.org/cl/
6458097
»»»
Yves Junqueira [Fri, 21 Sep 2012 19:54:33 +0000 (05:54 +1000)]
[release-branch.go1] crypto/rand: Example for Read.
««« backport
4738fd47e7a9
crypto/rand: Example for Read.
R=adg, remyoudompheng, rsc, r
CC=golang-dev
https://golang.org/cl/
6457085
»»»
Robert Griesemer [Fri, 21 Sep 2012 19:54:32 +0000 (05:54 +1000)]
[release-branch.go1] godoc: make id attributes unique
««« backport
b5dd89dce002
godoc: make id attributes unique
Some browsers (e.g. IE9) ignore the case of 'id' attributes
which can lead to conflicts. Prefix non-generated 'id's with
"pkg-" to make them different from any generated attribute.
Also: Added missing entry for "Other packages" to top-level
index.
Fixes #3851.
R=adg, dsymonds
CC=golang-dev
https://golang.org/cl/
6449105
»»»
Nigel Tao [Fri, 21 Sep 2012 19:54:32 +0000 (05:54 +1000)]
[release-branch.go1] image/jpeg: send a correct Start Of Scan (SOS) header.
««« backport
4a67b1f1e771
image/jpeg: send a correct Start Of Scan (SOS) header.
Section B.2.3 of http://www.w3.org/Graphics/JPEG/itu-t81.pdf discusses
the End of spectral selection (Se) byte.
Apparently many JPEG decoders ignore the Se byte (or let it through
with a warning), but some configurations reject them. For example,
http://download.blender.org/source/chest/blender_2.03_tree/jpeg/jcmaster.c
has these lines:
if (Ss != 0 || Se != DCTSIZE2-1 || Ah != 0 || Al != 0)
ERREXIT1(cinfo, JERR_BAD_PROG_SCRIPT, scanno);
Fixes #3916.
R=r
CC=golang-dev
https://golang.org/cl/
6459052
»»»
Brad Fitzpatrick [Fri, 21 Sep 2012 19:54:31 +0000 (05:54 +1000)]
[release-branch.go1] io: document ReaderFrom and WriterTo
««« backport
4e3a1967af09
io: document ReaderFrom and WriterTo
Fixes #3711
R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/
6445083
»»»
Yves Junqueira [Fri, 21 Sep 2012 19:54:31 +0000 (05:54 +1000)]
[release-branch.go1] text/template: fix range example.
««« backport
c37d3a28f6b0
text/template: fix range example.
R=r
CC=adg, gobot, golang-dev
https://golang.org/cl/
6449096
»»»
Shenghou Ma [Fri, 21 Sep 2012 19:54:30 +0000 (05:54 +1000)]
[release-branch.go1] doc: fix some HTML syntax errors
««« backport
4adee56240ac
doc: fix some HTML syntax errors
R=adg
CC=golang-dev
https://golang.org/cl/
6458043
»»»
Shenghou Ma [Fri, 21 Sep 2012 19:54:30 +0000 (05:54 +1000)]
[release-branch.go1] cmd/go: remove $WORK paths in generated binaries
««« backport
c1ce95068533
cmd/go: remove $WORK paths in generated binaries
Fixes #3748.
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/
6357064
»»»
Shenghou Ma [Fri, 21 Sep 2012 19:54:29 +0000 (05:54 +1000)]
[release-branch.go1] math, runtime: use a NaN that matches gcc's
««« backport
1f62df249175
math, runtime: use a NaN that matches gcc's
our old choice is not working properly at least on VFPv2 in
ARM1136JF-S (it's not preserved across float64->float32 conversions).
Fixes #3745.
R=dave, rsc
CC=golang-dev
https://golang.org/cl/
6344078
»»»
Shenghou Ma [Fri, 21 Sep 2012 19:54:29 +0000 (05:54 +1000)]
[release-branch.go1] runtime: remove unnecessary ROUND in alg.c
««« backport
4bd268b3c88a
runtime: remove unnecessary ROUND in alg.c
Introduced in CL
6452046 .
R=golang-dev, nigeltao, dave
CC=golang-dev
https://golang.org/cl/
6459051
»»»
Andrew Gerrand [Fri, 21 Sep 2012 19:54:29 +0000 (05:54 +1000)]
[release-branch.go1] syscall: fix plan9 build broken by CL
6458050
Brad Fitzpatrick [Fri, 21 Sep 2012 19:54:28 +0000 (05:54 +1000)]
[release-branch.go1] net: fix TCPListener file leak to child processes
««« backport
75a21418ac8f
net: fix TCPListener file leak to child processes
Hold ForkLock during dup of fd + cloexec in the net pkg,
per the locking policy documented in syscall/exec_unix.go.
R=golang-dev, dsymonds, adg
CC=golang-dev
https://golang.org/cl/
6457080
»»»
Andrew Gerrand [Fri, 21 Sep 2012 19:54:28 +0000 (05:54 +1000)]
[release-branch.go1] syscall: return EINVAL when string arguments have NUL characters
Benny Siegert [Fri, 21 Sep 2012 19:54:27 +0000 (05:54 +1000)]
[release-branch.go1] syscall: add some new syscall numbers from NetBSD-current
««« backport
98c1ecd82cb5
syscall: add some new syscall numbers from NetBSD-current
R=golang-dev
CC=golang-dev
https://golang.org/cl/
6454100
»»»
Russ Cox [Fri, 21 Sep 2012 19:54:27 +0000 (05:54 +1000)]
[release-branch.go1] bufio: discourage use of ReadLine
««« backport
9e2011d9ed4b
bufio: discourage use of ReadLine
Too many people use it without reading what it does.
Those people want ReadBytes or ReadString.
Fixes #3906.
R=golang-dev, iant, r
CC=golang-dev
https://golang.org/cl/
6442087
»»»
Rémy Oudompheng [Fri, 21 Sep 2012 19:54:26 +0000 (05:54 +1000)]
[release-branch.go1] cmd/8g: fix miscompilation due to BADWIDTH.
««« backport
f6a6fe780649
cmd/8g: fix miscompilation due to BADWIDTH.
Fixes #3899.
R=rsc
CC=golang-dev, remy
https://golang.org/cl/
6453084
»»»
Rémy Oudompheng [Fri, 21 Sep 2012 19:54:26 +0000 (05:54 +1000)]
[release-branch.go1] cmd/gc: accept switches on comparable arrays.
««« backport
d68605d10a6b
cmd/gc: accept switches on comparable arrays.
The compiler is incorrectly rejecting switches on arrays of
comparable types. It also doesn't catch incomparable structs
when typechecking the switch, leading to unreadable errors
during typechecking of the generated code.
Fixes #3894.
R=rsc
CC=gobot, golang-dev, r, remy
https://golang.org/cl/
6442074
»»»
Robert Griesemer [Fri, 21 Sep 2012 19:54:25 +0000 (05:54 +1000)]
[release-branch.go1] go/build: tiny cleanup
««« backport
30dfc01b473c
go/build: tiny cleanup
R=rsc
CC=golang-dev
https://golang.org/cl/
6453083
»»»
Alex Brainman [Fri, 21 Sep 2012 19:54:25 +0000 (05:54 +1000)]
[release-branch.go1] os: test that IsExist and IsNotExist handle PathError and LinkError
««« backport
32eb6dac3ff4
os: test that IsExist and IsNotExist handle PathError and LinkError
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
6442080
»»»
Robert Griesemer [Fri, 21 Sep 2012 19:54:24 +0000 (05:54 +1000)]
[release-branch.go1] go/scanner: fix minor typo
««« backport
c74762fb2e1d
go/scanner: fix minor typo
R=r
CC=golang-dev
https://golang.org/cl/
6442076
»»»
Robert Griesemer [Fri, 21 Sep 2012 19:54:24 +0000 (05:54 +1000)]
[release-branch.go1] go/ast: ast.Print must not crash with unexported fields
««« backport
d134e30c4d29
go/ast: ast.Print must not crash with unexported fields
Don't print unexported struct fields; their values are
not accessible via reflection.
Fixes #3898.
Also:
- added support for arrays
- print empty maps, arrays, slices, structs on one line
for a denser output
- added respective test cases
R=r
CC=golang-dev
https://golang.org/cl/
6454089
»»»
Shenghou Ma [Fri, 21 Sep 2012 19:54:23 +0000 (05:54 +1000)]
[release-branch.go1] runtime: round return value address in runtime.equal
««« backport
a7752d169d2e
runtime: round return value address in runtime.equal
Fixes #3866.
R=rsc, r, nigeltao
CC=golang-dev
https://golang.org/cl/
6452046
»»»
Alex Brainman [Fri, 21 Sep 2012 19:54:23 +0000 (05:54 +1000)]
[release-branch.go1] os: Rename error to fit IsExist
««« backport
104eb57df01b
os: Rename error to fit IsExist
Fixes #3828.
R=golang-dev, iant, rsc
CC=golang-dev
https://golang.org/cl/
6420056
»»»
Rémy Oudompheng [Fri, 21 Sep 2012 19:54:22 +0000 (05:54 +1000)]
[release-branch.go1] cmd/gc: fix inlining bug with receive operator.
««« backport
d872ed20fccb
cmd/gc: fix inlining bug with receive operator.
The receive operator was given incorrect precedence
resulting in incorrect deletion of parentheses.
Fixes #3843.
R=rsc
CC=golang-dev, remy
https://golang.org/cl/
6442049
»»»
Shenghou Ma [Fri, 21 Sep 2012 19:54:22 +0000 (05:54 +1000)]
[release-branch.go1] cmd/cgo: use 1 as last entry for __cgodebug_data
««« backport
aeaab9df5600
cmd/cgo: use 1 as last entry for __cgodebug_data
LLVM-based gcc will place all-zero data in a zero-filled
section, but our debug/macho can't handle that.
Fixes #3821.
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/
6444049
»»»
Rob Pike [Fri, 21 Sep 2012 19:54:21 +0000 (05:54 +1000)]
[release-branch.go1] regexp: fix glitch in doc for FindReaderIndex
««« backport
6f790a92b3d2
regexp: fix glitch in doc for FindReaderIndex
Fixes #3878.
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/
6457054
»»»
Andrew Gerrand [Fri, 21 Sep 2012 19:54:21 +0000 (05:54 +1000)]
[release-branch.go1] doc: remove mention of weekly tag from source install doc
««« backport
8c4b1b7ce761
doc: remove mention of weekly tag from source install doc
R=golang-dev, dsymonds, bradfitz
CC=golang-dev
https://golang.org/cl/
6442062
»»»
Russ Cox [Fri, 21 Sep 2012 19:54:20 +0000 (05:54 +1000)]
[release-branch.go1] cmd/go: show $GOPATH in 'go env' output
««« backport
d6d7de5aa8ed
cmd/go: show $GOPATH in 'go env' output
Also, sort output.
R=golang-dev, patrick, dave, iant
CC=golang-dev, patrick
https://golang.org/cl/
6446064
»»»
Brad Fitzpatrick [Fri, 21 Sep 2012 19:54:20 +0000 (05:54 +1000)]
[release-branch.go1] net/http: don't allow zero byte in FileServer paths
««« backport
2307a931664e
net/http: don't allow zero byte in FileServer paths
Should probably be fixed in the syscall package, either
additional or instead of this CL.
Fixes #3842
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/
6442061
»»»
Daniel Morsing [Fri, 21 Sep 2012 19:54:19 +0000 (05:54 +1000)]
[release-branch.go1] cmd/gc: point "no new variables" error at right line number.
««« backport
98788e8973f2
cmd/gc: point "no new variables" error at right line number.
Fixes #3856.
R=dsymonds, rsc
CC=golang-dev
https://golang.org/cl/
6455056
»»»
Russ Cox [Fri, 21 Sep 2012 19:54:19 +0000 (05:54 +1000)]
[release-branch.go1] syscall: apply comment from Mikioh
««« backport
d191515c80fb
syscall: apply comment from Mikioh
This comment was suggested in CL
6456045
but never got applied.
R=mikioh, mikioh.mikioh
CC=golang-dev
https://golang.org/cl/
6447056
»»»
Alexey Borzenkov [Fri, 21 Sep 2012 19:54:18 +0000 (05:54 +1000)]
[release-branch.go1] syscall: workaround accept() bug on Darwin
««« backport
0eae95b0307a
syscall: workaround accept() bug on Darwin
Darwin kernels have a bug in accept() where error result from
an internal call is not checked and socket is accepted instead
of ECONNABORTED error. However, such sockets have no sockaddr,
which results in EAFNOSUPPORT error from anyToSockaddr, making
Go http servers running on Mac OS X easily susceptible to
denial of service from simple port scans with nmap.
Fixes #3849.
R=golang-dev, adg, mikioh.mikioh
CC=golang-dev
https://golang.org/cl/
6456045
»»»
Benny Siegert [Fri, 21 Sep 2012 19:54:18 +0000 (05:54 +1000)]
[release-branch.go1] runtime/cgo: fix netbsd build
««« backport
601878acd597
runtime/cgo: fix netbsd build
Copy over freebsd.c to netbsd.c.
Fixes #3823.
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/
6398045
»»»
David Symonds [Fri, 21 Sep 2012 19:54:17 +0000 (05:54 +1000)]
[release-branch.go1] misc/vim: fix :Import insertion heuristic.
««« backport
9bf2225c38eb
misc/vim: fix :Import insertion heuristic.
If a factored import group has a blank line, assume it is dividing
separate groups of imports (e.g. standard library vs. site-specific).
import (
"bytes"
"io"
"mycorp/package"
)
The most common case is inserting new standard library imports,
which are usually (stylistically) the first group, so we should drop
"net" in the above example immediately after "io".
Since this logic is getting non-trivial, add a test.
R=golang-dev, minux.ma, franciscossouza
CC=golang-dev
https://golang.org/cl/
6445043
»»»
Rob Pike [Fri, 21 Sep 2012 19:54:17 +0000 (05:54 +1000)]
[release-branch.go1] flag: fix bug in handling of booleans on error
««« backport
a36c0344826a
flag: fix bug in handling of booleans on error
Fixes #3869.
R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/
6448072
»»»
Shenghou Ma [Fri, 21 Sep 2012 19:54:16 +0000 (05:54 +1000)]
[release-branch.go1] log/syslog: don't append \n if there is one
««« backport
6556a8d85dd6
log/syslog: don't append \n if there is one
pkg log already appends a linefeed to the log message,
so log/syslog doesn't need to append another.
R=golang-dev, bradfitz, r
CC=golang-dev
https://golang.org/cl/
6441048
»»»
Alex Brainman [Fri, 21 Sep 2012 19:54:16 +0000 (05:54 +1000)]
[release-branch.go1] os: move epipecheck from file_posix.go and into file_unix.go to fix windows build
««« backport
d127749038e8
os: move epipecheck from file_posix.go and into file_unix.go to fix windows build
R=golang-dev
CC=golang-dev
https://golang.org/cl/
6450058
»»»
Dmitriy Vyukov [Fri, 21 Sep 2012 19:54:15 +0000 (05:54 +1000)]
[release-branch.go1] os: fix data race in epipecheck()
««« backport
8b3bf65c620c
os: fix data race in epipecheck()
Fixes #3860.
R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/
6443051
»»»
Ian Lance Taylor [Fri, 21 Sep 2012 19:54:14 +0000 (05:54 +1000)]
[release-branch.go1] runtime: ignore signal 33 == SIGSETXID on GNU/Linux
««« backport
bfa4e1f1027f
runtime: ignore signal 33 == SIGSETXID on GNU/Linux
When a cgo program calls setuid, setgid, etc., the GNU/Linux
pthread library sends signal SIGSETXID to each thread to tell
it to update its UID info. If Go is permitted to intercept
the default SIGSETXID signal handler, the program will hang.
This patch tells the runtime package to not try to intercept
SIGSETXID on GNU/Linux. This will be odd if a Go program
wants to try to use that signal, but it means that cgo
programs that call setuid, etc., won't hang.
Fixes #3871.
R=rsc, r, minux.ma, bradfitz
CC=golang-dev
https://golang.org/cl/
6455050
»»»
Robert Griesemer [Fri, 21 Sep 2012 19:54:14 +0000 (05:54 +1000)]
[release-branch.go1] go/printer: don't crash if ast.FuncType.Params is nil
««« backport
7f6a0510d3c9
go/printer: don't crash if ast.FuncType.Params is nil
The go/ast comment for FuncType.Params says that the field may be nil.
Make sure the printer accepts such a value. The go/parser always sets
the field (to provide parenthesis position information), but a program
creating a Go AST from scatch may not.
Added corresponding test case.
Fixes #3870.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
6448060
»»»
Robert Griesemer [Fri, 21 Sep 2012 19:54:13 +0000 (05:54 +1000)]
[release-branch.go1] A+C: added Andrew Wilkins (individual contributor)
««« backport
b22edea8aed4
A+C: added Andrew Wilkins (individual contributor)
R=rsc, minux.ma, iant
CC=golang-dev
https://golang.org/cl/
6447050
»»»
Ian Lance Taylor [Fri, 21 Sep 2012 19:54:13 +0000 (05:54 +1000)]
[release-branch.go1] cgo: fix declarations in _cgo_export.c
««« backport
6751a0e1a6a4
cgo: fix declarations in _cgo_export.c
Declare crosscall2. Declare the functions passed to it as
returning void, rather than relying on implicit return type.
R=golang-dev, minux.ma
CC=golang-dev
https://golang.org/cl/
6432060
»»»
Brad Fitzpatrick [Fri, 21 Sep 2012 19:54:12 +0000 (05:54 +1000)]
[release-branch.go1] testing: allow concurrent use of T and B
««« backport
7a67d277c7e8
testing: allow concurrent use of T and B
Notably, allow concurrent logging and failing.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/
6453045
»»»
Mikio Hara [Fri, 21 Sep 2012 19:54:12 +0000 (05:54 +1000)]
[release-branch.go1] net: fix comment
««« backport
5a0aafb7fd8d
net: fix comment
RemoteAddr returns not only UDPAddr but IPAddr.
R=golang-dev, dave
CC=golang-dev
https://golang.org/cl/
6401054
»»»
Rob Pike [Fri, 21 Sep 2012 19:54:11 +0000 (05:54 +1000)]
[release-branch.go1] text/template: fix bug in map indexing
««« backport
0748cd92ed76
text/template: fix bug in map indexing
If the key is not present, return value of the type of the element
not the type of the key. Also fix a test that should have caught this case.
Fixes #3850.
R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/
6405078
»»»
Rob Pike [Fri, 21 Sep 2012 19:54:11 +0000 (05:54 +1000)]
[release-branch.go1] encoding/gob: revert
6348067 , which broke compatibility
««« backport
3357d8d34ab8
encoding/gob: revert
6348067 , which broke compatibility
Add commentary to explain better what's going on, but the
code change is a simple one-line reversal to the previous
form.
R=rsc
CC=golang-dev
https://golang.org/cl/
6428072
»»»
Andrew Gerrand [Fri, 21 Sep 2012 19:54:10 +0000 (05:54 +1000)]
[release-branch.go1] doc: add two I/O talks to "Talks" section
««« backport
ddaabb722563
doc: add two I/O talks to "Talks" section
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/
6422056
»»»
Patrick Mylund Nielsen [Fri, 21 Sep 2012 19:54:10 +0000 (05:54 +1000)]
[release-branch.go1] encoding/binary: fix typo: ReadVarint returns an int64, not a uint64.
««« backport
2f39e6389d55
encoding/binary: fix typo: ReadVarint returns an int64, not a uint64.
R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/
6432062
»»»
Mikio Hara [Fri, 21 Sep 2012 19:54:10 +0000 (05:54 +1000)]
[release-branch.go1] net: fix file descriptor leak on FileListener, FileConn and FilePacketConn
««« backport
aee5a494a65c
net: fix file descriptor leak on FileListener, FileConn and FilePacketConn
R=golang-dev, dave, r
CC=golang-dev
https://golang.org/cl/
6430062
»»»
Ian Lance Taylor [Fri, 21 Sep 2012 19:54:09 +0000 (05:54 +1000)]
[release-branch.go1] cgo: add -gccgopkgpath option to match gccgo -fgo-pkgpath
««« backport
06e3a4c30dfb
cgo: add -gccgopkgpath option to match gccgo -fgo-pkgpath
R=golang-dev, r, iant
CC=golang-dev
https://golang.org/cl/
6416056
»»»
Mikio Hara [Fri, 21 Sep 2012 19:54:09 +0000 (05:54 +1000)]
[release-branch.go1] net: fix typo
««« backport
3019a3e15027
net: fix typo
R=golang-dev, bsiegert, r
CC=golang-dev
https://golang.org/cl/
6428050
»»»
Rob Pike [Fri, 21 Sep 2012 19:54:08 +0000 (05:54 +1000)]
[release-branch.go1] sync: mention that WaitGroup.Add panics
««« backport
05f9fa32500a
sync: mention that WaitGroup.Add panics
Fixes #3839.
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/
6428053
»»»
Rémy Oudompheng [Fri, 21 Sep 2012 19:54:08 +0000 (05:54 +1000)]
[release-branch.go1] testing: fix memory blowup when formatting many lines.
««« backport
5e7fd762f356
testing: fix memory blowup when formatting many lines.
Fixes #3830.
R=golang-dev, r
CC=golang-dev, remy
https://golang.org/cl/
6373047
»»»
Rob Pike [Fri, 21 Sep 2012 19:54:07 +0000 (05:54 +1000)]
[release-branch.go1] faq: add status section
««« backport
2819b5a4f07d
faq: add status section
Fixes #3822.
R=golang-dev, r, dsymonds, minux.ma, adg
CC=golang-dev
https://golang.org/cl/
6395043
»»»
Adam Langley [Fri, 21 Sep 2012 19:54:07 +0000 (05:54 +1000)]
[release-branch.go1] A+C: Peter Armitage (individual CLA)
««« backport
0423072b54f2
A+C: Peter Armitage (individual CLA)
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/
6392065
»»»
Nigel Tao [Fri, 21 Sep 2012 19:54:06 +0000 (05:54 +1000)]
[release-branch.go1] compress/flate: fix panic when nlit is out of bounds.
««« backport
ecd688de20fb
compress/flate: fix panic when nlit is out of bounds.
Fixes #3815.
R=r
CC=golang-dev
https://golang.org/cl/
6352109
»»»
Benny Siegert [Fri, 21 Sep 2012 19:54:06 +0000 (05:54 +1000)]
[release-branch.go1] os: add missing full stop in comment
««« backport
c61c67c7b924
os: add missing full stop in comment
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/
6399047
»»»
Rémy Oudompheng [Fri, 21 Sep 2012 19:54:05 +0000 (05:54 +1000)]
[release-branch.go1] cmd/gc: reject use of ... with multiple-valued expressions.
««« backport
6d5faedd95bc
cmd/gc: reject use of ... with multiple-valued expressions.
Fixes #3334.
R=golang-dev, r
CC=golang-dev, remy
https://golang.org/cl/
6350103
»»»
Rémy Oudompheng [Fri, 21 Sep 2012 19:54:05 +0000 (05:54 +1000)]
[release-branch.go1] cmd/gc: avoid an internal error on invalid type switch.
««« backport
254232c99b3e
cmd/gc: avoid an internal error on invalid type switch.
The error was caused by a call to implements() even when
the type switch variable was not an interface.
Fixes #3786.
R=golang-dev, r
CC=golang-dev, remy
https://golang.org/cl/
6354102
»»»
Rémy Oudompheng [Fri, 21 Sep 2012 19:54:04 +0000 (05:54 +1000)]
[release-branch.go1] cmd/gc: fix error message for type errors involving conversions.
««« backport
a281d4bd1ba6
cmd/gc: fix error message for type errors involving conversions.
Fixes #3818.
R=golang-dev, rsc, r
CC=golang-dev, remy
https://golang.org/cl/
6352106
»»»
Andrew Gerrand [Fri, 21 Sep 2012 19:54:04 +0000 (05:54 +1000)]
[release-branch.go1] encoding/gob: fix check for short input in slice decode
Rémy Oudompheng [Fri, 21 Sep 2012 19:54:03 +0000 (05:54 +1000)]
[release-branch.go1] spec: correct typo in string conversion examples.
««« backport
65de4b905541
spec: correct typo in string conversion examples.
R=golang-dev, dave, r
CC=golang-dev, remy
https://golang.org/cl/
6378046
»»»
Adam Langley [Fri, 21 Sep 2012 19:54:03 +0000 (05:54 +1000)]
[release-branch.go1] crypto/rsa: left-pad PKCS#1 v1.5 outputs.
««« backport
46ca86e70e96
crypto/rsa: left-pad PKCS#1 v1.5 outputs.
OpenSSL requires that RSA signatures be exactly the same byte-length
as the modulus. Currently it'll reject ~1/256 of our signatures: those
that end up a byte shorter.
Fixes #3796.
R=golang-dev, edsrzf, r
CC=golang-dev
https://golang.org/cl/
6352093
»»»
Dave Cheney [Fri, 21 Sep 2012 19:54:02 +0000 (05:54 +1000)]
[release-branch.go1] website: various html fixes
««« backport
744f0397f41a
website: various html fixes
Fixes #3424.
R=fullung, adg
CC=golang-dev
https://golang.org/cl/
6343088
»»»
Adam Langley [Fri, 21 Sep 2012 19:54:02 +0000 (05:54 +1000)]
[release-branch.go1] crypto/x509: exempt broken Entrust certificate from checks.
««« backport
8241ffc8686e
crypto/x509: exempt broken Entrust certificate from checks.
Entrust have issued a root certificate that's not marked as valid for
signing certificates.
This results in Go programs failing to validate certificates that
chain up to this root (i.e. gateway.push.apple.com:2195).
Although this is clearly a mistake on Entrust's part, it seems that we
will have to bodge around it.
R=golang-dev, dave, r
CC=golang-dev
https://golang.org/cl/
6346064
»»»
David G. Andersen [Fri, 21 Sep 2012 19:54:01 +0000 (05:54 +1000)]
[release-branch.go1] pkg: Removing duplicated words ("of of", etc.), mostly from comments.
««« backport
ce3a981ad1ef
pkg: Removing duplicated words ("of of", etc.), mostly from comments.
Ran 'double.pl' on the pkg tree to identify doubled words.
One change to an error string return in x509; the rest are in comments.
Thanks to Matt Jibson for the idea.
R=golang-dev, bsiegert
CC=golang-dev
https://golang.org/cl/
6344089
»»»
Matt Jibson [Fri, 21 Sep 2012 19:54:01 +0000 (05:54 +1000)]
[release-branch.go1] A+C: correct Matt Jibson
««« backport
63dae3ba6a6d
A+C: correct Matt Jibson
R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/
6344088
»»»
Matthew William Jibson [Fri, 21 Sep 2012 19:54:01 +0000 (05:54 +1000)]
[release-branch.go1] doc: various "the the" and other typos
««« backport
74c5c02910de
doc: various "the the" and other typos
R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/
6355076
»»»
David Symonds [Fri, 21 Sep 2012 19:54:00 +0000 (05:54 +1000)]
[release-branch.go1] A+C: Matthew Jibson (individual CLA).
««« backport
9349fc3302f5
A+C: Matthew Jibson (individual CLA).
R=golang-dev, alex.brainman
CC=golang-dev
https://golang.org/cl/
6349082
»»»
Shenghou Ma [Fri, 21 Sep 2012 19:53:59 +0000 (05:53 +1000)]
[release-branch.go1] misc/chrome/gophertool: fix manifest
««« backport
100ddb84c85d
misc/chrome/gophertool: fix manifest
according to http://code.google.com/chrome/extensions/browserAction.html,
it should use "default_popup" instead of "popup".
R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/
6349077
»»»
Robert Griesemer [Fri, 21 Sep 2012 19:53:59 +0000 (05:53 +1000)]
[release-branch.go1] reflect: reflect.Zero results are neither addressable nor settable
««« backport
21130d62eeb0
reflect: reflect.Zero results are neither addressable nor settable
This could be deduced from "The Laws of Reflection" but it seems
worthwhile highlighting it.
R=r
CC=golang-dev
https://golang.org/cl/
6350073
»»»
Rob Pike [Fri, 21 Sep 2012 19:53:58 +0000 (05:53 +1000)]
[release-branch.go1] encoding/gob: fix bug in Register
««« backport
c89f17a9ff4f
encoding/gob: fix bug in Register
The old code added a star but did not indirect the reflect.Type.
R=bradfitz
CC=golang-dev
https://golang.org/cl/
6348067
»»»