- 03 Dec, 2015 3 commits
-
-
Rahul Chaudhry authored
From Android release M (Marshmallow), hard linking files is blocked and an attempt to call link() on a file will return EACCES. - https://code.google.com/p/android-developer-preview/issues/detail?id=3150 Change-Id: Ifdadaa31e3d5ee330553f45db6c001897dc955be Reviewed-on: https://go-review.googlesource.com/17339Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
-
Chris Broadfoot authored
Change-Id: I6bee207db7485f96a499f51b2d1346c35e086d41 Reviewed-on: https://go-review.googlesource.com/17337Reviewed-by: Russ Cox <rsc@golang.org>
-
Chris Broadfoot authored
Change-Id: Ib6a9e131113523e6b1e5b7604480028b9ffbfa93 Reviewed-on: https://go-review.googlesource.com/17178Reviewed-by: Andrew Gerrand <adg@golang.org>
-
- 02 Dec, 2015 17 commits
-
-
Alexandre Cesaro authored
Add the test index so it is easier to find which test case failed. Change-Id: Ic04682651b26b137355950ff0c51bdbdb1d85a9c Reviewed-on: https://go-review.googlesource.com/17351Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Rahul Chaudhry authored
Also, enable test misc/cgo/testcshared for android/arm64. c/17245 and c/17246 provide the missing pieces for making this test work. "androidtest.bash" now passes on a Nexus 9 (volantis) device running Android build "LMY48T". Change-Id: Icb9fd2d17d97e0f04cb18d0cd91640c80fbd3fb4 Reviewed-on: https://go-review.googlesource.com/17333Reviewed-by: Ian Lance Taylor <iant@golang.org>
-
Rahul Chaudhry authored
On android, runtime.tls_g is a normal variable. TLS offset is computed in x_cgo_inittls. Change-Id: I18bc9a736d5fb2a89d0f798956c754e3c10d10e2 Reviewed-on: https://go-review.googlesource.com/17246Reviewed-by: David Crawshaw <crawshaw@golang.org>
-
Rahul Chaudhry authored
On android, runtime.tls_g is a normal variable. TLS offset is computed in x_cgo_inittls. Change-Id: I64cfd3543040776dcdf73cad8dba54fc6aaf6f35 Reviewed-on: https://go-review.googlesource.com/17245Reviewed-by: David Crawshaw <crawshaw@golang.org>
-
Michael Hudson-Doyle authored
runtime.stackBarrier is a strange function: it is only ever "called" by smashing its address into a LR slot on the stack. Calling it like this certainly does not adhere to the rule that r12 is set to the global entry point before calling it and the prologue instrutions that compute r2 from r12 in fact just corrupt r2, which is bad because the function that stackBarrier returns to probably uses r2 to access global data. Fortunately stackBarrier itself does not access any global data and so does not depend on the value of r2, meaning we can ignore the ABI rules and simply skip inserting the prologue instructions into this specific function. Fixes 64bit.go, append.go and fixedbugs/issue13169.go from "cd test; go run run.go -linkshared". Change-Id: I606864133a83935899398e2d42edd08a946aab24 Reviewed-on: https://go-review.googlesource.com/17281Reviewed-by: Austin Clements <austin@google.com>
-
Ian Lance Taylor authored
Fixes #13423. Change-Id: I41bb45790cca36c57a107796f0eca61287acb2a9 Reviewed-on: https://go-review.googlesource.com/17332 Run-TryBot: Ian Lance Taylor <iant@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Håvard Haugen authored
Move test for isblank into addmethod so that most of the type checking for methods is also performed for blank methods. Fixes #11366. Change-Id: I13d554723bf96d906d0b3ff390d7b7c87c1a5020 Reviewed-on: https://go-review.googlesource.com/16866Reviewed-by: Robert Griesemer <gri@golang.org>
-
INADA Naoki authored
Long lived connections may make some DB operation difficult. (e.g. retiring load balanced DB server.) So SetConnMaxLifetime closes long lived connections. It can be used to limit maximum idle time, too. Closing idle connections reduces active connections while application is idle and avoids connections are closed by server side (cause errBadConn while querying). fixes #9851 Change-Id: I2e8e824219c1bee7f4b885d38ed96d11b7202b56 Reviewed-on: https://go-review.googlesource.com/6580 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Alexandre Cesaro authored
When the name of an Address contains non-ASCII characters, Address.String() used mime.QEncoding to encode the name. However certain characters are forbidden when an encoded-word is in a phrase context (see RFC 2047 section 5.3) and these characters are not encoded by mime.QEncoding. In this case we now use mime.BEncoding (base64 encoding) so that forbidden characters are also encoded. Fixes #11292 Change-Id: I52db98b41ece439295e97d7e94c8190426f499c2 Reviewed-on: https://go-review.googlesource.com/16012Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Ian Lance Taylor authored
The old code was assuming that a PT_NOTE segment never had more than one note, but there is no such requirement. Fixes #13364. Change-Id: I3f6b3716130bf7af6abe81b8e10571a8c7cd943c Reviewed-on: https://go-review.googlesource.com/17331 Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: Russ Cox <rsc@golang.org>
-
Joe Tsai authored
Commit 7a1fb95d strips non-free license from Mark.Twain-Tom.Sawyer.txt, but forgot to remove it from the compressed version of the file. Update #13216 Change-Id: I60f53275d56ba5baa6898db47b1d41f85e985c00 Reviewed-on: https://go-review.googlesource.com/17264Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Joe Tsai authored
Motivation for change: * Recursive logic is hard to follow, since it tends to apply things in reverse. On the other hand, the tar formats tend to describe meta headers as affecting the next entry. * Recursion also applies changes in the wrong order. Two test files are attached that use multiple headers. The previous Go behavior differs from what GNU and BSD tar do. Change-Id: Ic1557256fc1363c5cb26570e5d0b9f65a9e57341 Reviewed-on: https://go-review.googlesource.com/14624 Run-TryBot: Joe Tsai <joetsai@digital-static.net> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Brad Fitzpatrick authored
This mirrors the same behavior and API from the server code to the client side: if TLSNextProto is nil, HTTP/2 is on by default for both. If it's non-nil, the user was trying to do something fancy and step out of their way. Updates #6891 Change-Id: Ia31808b71f336a8d5b44b985591d72113429e1d4 Reviewed-on: https://go-review.googlesource.com/17300Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Ian Lance Taylor authored
The existing code has partial support for -07 (just the hours of a time zone offset). Complete the support, add support for Z07, and add a few tests. Fixes #13426. Change-Id: Ic6377bbf3e65b4bb761b9779f7e80c07ce4f57e8 Reviewed-on: https://go-review.googlesource.com/17260Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Joe Tsai authored
Motivations for this change: * It allows these functions to be used outside of Reader/Writer. * It allows these functions to be more easily unit tested. Change-Id: Iebe2b70bdb8744371c9ffa87c24316cbbf025b59 Reviewed-on: https://go-review.googlesource.com/15113Reviewed-by: Russ Cox <rsc@golang.org> Run-TryBot: Joe Tsai <joetsai@digital-static.net> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Ingo Oeser authored
Fixes #12492 Change-Id: I8bb512027639301e2f2c41aab84e6d06ae88b137 Reviewed-on: https://go-review.googlesource.com/14312Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Benjamin Prosnitz authored
Fixes #13090 Change-Id: I5612d792dabdff89bd0cec57dc2cacf9be7ebf64 Reviewed-on: https://go-review.googlesource.com/16341 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
- 01 Dec, 2015 15 commits
-
-
Russ Cox authored
Fixes #13011. Change-Id: Ia4c67880fca83f4298ff6bb1b217ec26c8c83427 Reviewed-on: https://go-review.googlesource.com/17231Reviewed-by: David Crawshaw <crawshaw@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
-
Russ Cox authored
It's not a group: must handle the inside as a sequence of literal chars, not a single literal string. That is, \Qab\E+ is the same as ab+, not (ab)+. Fixes #11187. Change-Id: I5406d05ccf7efff3a7f15395bdb0cfb2bd23a8ed Reviewed-on: https://go-review.googlesource.com/17233Reviewed-by: David Crawshaw <crawshaw@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Carlos Cirello authored
Change-Id: I5be18b68602a7ebb740cf05924236ce17e386e55 Reviewed-on: https://go-review.googlesource.com/17295 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Russ Cox authored
Fixes #13108. Change-Id: I474cc2a3b7ced1c9eb978fc815f9c6bae9fb3ecc Reviewed-on: https://go-review.googlesource.com/17235Reviewed-by: Ian Lance Taylor <iant@golang.org>
-
Blake Gentry authored
If we try to reuse a connection that the server is in the process of closing, we may end up successfully writing out our request (or a portion of our request) only to find a connection error when we try to read from (or finish writing to) the socket. This manifests as an EOF returned from the Transport's RoundTrip. The issue, among others, is described in #4677. This change follows some of the Chromium guidelines for retrying idempotent requests only when the connection has been already been used successfully and no header data has yet been received for the response. As part of this change, an unexported error was defined for errMissingHost, which was previously defined inline. errMissingHost is the only non-network error returned from a Request's Write() method. Additionally, this breaks TestLinuxSendfile because its test server explicitly triggers the type of scenario this change is meant to retry on. Because that test server stops accepting conns on the test listener before the retry, the test would time out. To fix this, the test was altered to use a non-idempotent test type (POST). Change-Id: I1ca630b944f0ed7ec1d3d46056a50fb959481a16 Reviewed-on: https://go-review.googlesource.com/3210Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
-
David Benjamin authored
The empty string is not a valid DER integer. DER also requires that values be minimally-encoded, so excess padding with leading 0s (0xff for negative numbers) is forbidden. (These rules also apply to BER, incidentally.) Fixes #12622. Change-Id: I041f94e34a8afa29dbf94dd8fc450944bc91c9c3 Reviewed-on: https://go-review.googlesource.com/17008Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Joe Tsai authored
Motivations: * Use of strconv.ParseInt does not properly treat integers as 64bit, preventing this function from working properly on 32bit machines. * Use of io.ReadFull does not properly detect truncated streams when the file suddenly ends on a block boundary. * The function blindly trusts user input for numEntries and allocates memory accordingly. * The function does not validate that numEntries is not negative, allowing a malicious sparse file to cause a panic during make. In general, this function was overly complicated for what it was accomplishing and it was hard to reason that it was free from bounds errors. Instead, it has been rewritten and relies on bytes.Buffer.ReadString to do the main work. So long as invariants about the number of '\n' in the buffer are maintained, it is much easier to see why this approach is correct. Change-Id: Ibb12c4126c26e0ea460ea063cd17af68e3cf609e Reviewed-on: https://go-review.googlesource.com/15174Reviewed-by: Russ Cox <rsc@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Joe Tsai authored
Certain special type-flags, specifically 1, 2, 3, 4, 5, 6, do not have a data section. Thus, regardless of what the size field says, we should not attempt to read any data for these special types. The relevant PAX and USTAR specification says: <<< If the typeflag field is set to specify a file to be of type 1 (a link) or 2 (a symbolic link), the size field shall be specified as zero. If the typeflag field is set to specify a file of type 5 (directory), the size field shall be interpreted as described under the definition of that record type. No data logical records are stored for types 1, 2, or 5. If the typeflag field is set to 3 (character special file), 4 (block special file), or 6 (FIFO), the meaning of the size field is unspecified by this volume of POSIX.1-2008, and no data logical records shall be stored on the medium. Additionally, for type 6, the size field shall be ignored when reading. If the typeflag field is set to any other value, the number of logical records written following the header shall be (size+511)/512, ignoring any fraction in the result of the division. >>> Contrary to the specification, we do not assert that the size field is zero for type 1 and 2 since we liberally accept non-conforming formats. Change-Id: I666b601597cb9d7a50caa081813d90ca9cfc52ed Reviewed-on: https://go-review.googlesource.com/16614Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Russ Cox authored
Or at least make them true. Fixes #12237. Change-Id: I3c92a07233b2174c5731d6fa7fbb9ca3a97beb6b Reviewed-on: https://go-review.googlesource.com/17237Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Colin Cross authored
Implement setting the compression level for a zip archive by registering a per-Writer compressor through Writer.RegisterCompressor. If no compressors are registered, fall back to the ones registered at the package level. Also implements per-Reader decompressors. Fixes #8359 Change-Id: I93b27c81947b0f817b42e0067aa610ff267fdb21 Reviewed-on: https://go-review.googlesource.com/16669Reviewed-by: Joe Tsai <joetsai@digital-static.net> Run-TryBot: Joe Tsai <joetsai@digital-static.net> Reviewed-by: Klaus Post <klauspost@gmail.com> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
-
Aleksandr Demakin authored
Use sync.Once to ensure, that 'offsets' field is initialized once only in a threadsafe way. Fixes #12887 Change-Id: I90ef929c421ccd3094339c67a39b02d8f2e47211 Reviewed-on: https://go-review.googlesource.com/16013Reviewed-by: Robert Griesemer <gri@golang.org>
-
Brad Fitzpatrick authored
A Content-Type always has a slash (type/subtype) A Content-Disposition does not (e.g. "attachment" or "line"). A "media type" is either one of those, plus optional parameters afterwards. Our ParseMediaType and FormatMediaType weren't consistent in whether they permitted Content-Dispositions. Now they both do. Fixes #11289 Change-Id: Ia75723c9d7adb7f4de0f65482780f823cdadb5bd Reviewed-on: https://go-review.googlesource.com/17135Reviewed-by: Russ Cox <rsc@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Brad Fitzpatrick authored
Fix an old bug where media type parameter values could be escaped by either double quotes (per the spec) or single quotes (due to my bug). The original bug was introduced by me in git rev 90e4ece3 (https://golang.org/cl/4430049) in April 2011 when adding more tests from http://greenbytes.de/tech/tc2231/ and misinterpreting the expected value of test "attwithfntokensq" and not apparently thinking about it enough. No known spec or existing software produces or expects single quotes around values. In fact, it would have be a parsing ambiguity if it were allowed: the string `a=', b='` could parse as two keys "a" and "b" both with value "'", or it could be parse as a single key "a" with value "', b=". Fixes #11291 Change-Id: I6de58009dd47dcabb120b017245d237cb7b1e89a Reviewed-on: https://go-review.googlesource.com/17136Reviewed-by: Russ Cox <rsc@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Marcel van Lohuizen authored
Check that it now properly handles \xC0 and \xC1. Fixes #11733. Change-Id: I66cfe0d43f9d123d4c4509a3fa18b9b6380dfc39 Reviewed-on: https://go-review.googlesource.com/17225Reviewed-by: Russ Cox <rsc@golang.org>
-
Michael Hudson-Doyle authored
The ppc64le shared library ABI demands that r12 is set to a function's global entrypoint before jumping to the global entrypoint. Not doing so means that handling signals that usually panic actually crashes (and so, e.g. can't be recovered). Fixes several failures of "cd test; go run run.go -linkshared". Change-Id: Ia4d0da4c13efda68340d38c045a52b37c2f90796 Reviewed-on: https://go-review.googlesource.com/17280Reviewed-by: Ian Lance Taylor <iant@golang.org>
-
- 30 Nov, 2015 5 commits
-
-
Robert Griesemer authored
Fixes #13420. Change-Id: Id64ebd0527881450fdaffbb66d8b1831a6b7c43c Reviewed-on: https://go-review.googlesource.com/17263Reviewed-by: Rob Pike <r@golang.org>
-
Robert Griesemer authored
Old parser remains. Change-Id: I05ef1737802e23afc2c2129f58cb66feef8e3425 Reviewed-on: https://go-review.googlesource.com/17244Reviewed-by: David Crawshaw <crawshaw@golang.org>
-
Robert Griesemer authored
Fixes #13245. Change-Id: I87be63cc7b27f70ca2f9fb6bc9908b9061fe3d9d Reviewed-on: https://go-review.googlesource.com/17203Reviewed-by: Chris Manghane <cmang@golang.org>
-
Brad Fitzpatrick authored
Updates to x/net rev 195180cf (golang.org/cl/17134, http2: merge duplicate Transport dials) Change-Id: I50b9c73b30c6a21e725aad80126b713d8b0fa362 Reviewed-on: https://go-review.googlesource.com/17261Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-
Burcu Dogan authored
Fixes #13421. Change-Id: Ic0fc0d0a8e86d2be23db12ddd1a8a8105e26ee56 Reviewed-on: https://go-review.googlesource.com/17250Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Burcu Dogan <jbd@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org>
-