1
0
mirror of https://github.com/golang/go synced 2024-09-25 01:10:13 -06:00
Commit Graph

8189 Commits

Author SHA1 Message Date
Rob Pike
88a8ac08b9 gotest: fix a bug in error handling.
If the command couldn't be found, argv[0] would be wiped.
Also, fix a print statement not to refer to make - it was a vestige of a prior form.

R=rsc, gri
CC=golang-dev
https://golang.org/cl/4360048
2011-04-05 12:51:10 -07:00
Adam Langley
906b2e7679 crypto/des: cleanups
R=rsc
CC=golang-dev
https://golang.org/cl/4315050
2011-04-05 15:40:48 -04:00
Adam Langley
2db1769d7b crypto/block: remove deprecated package.
R=rsc
CC=golang-dev
https://golang.org/cl/4315051
2011-04-05 15:23:40 -04:00
Peter Mundy
b2bf14acd9 gotest: fixes for [^.]_test file pattern
R=rsc, r
CC=golang-dev
https://golang.org/cl/4339054
2011-04-05 11:49:44 -07:00
Rob Pike
e6b1d424c4 spec: add parens missing from "protect" example.
Fixes #1665.

R=gri
CC=golang-dev
https://golang.org/cl/4351051
2011-04-05 11:01:25 -07:00
Russ Cox
de3aac609c gofix: don't rewrite O_APPEND opens
R=r, rog
CC=golang-dev
https://golang.org/cl/4364041
2011-04-05 11:12:02 -04:00
Yasuhiro Matsumoto
7098f3d442 crypto/des: new package providing implementations of DES and TDEA
Original code by Chris Lennert <cale...@gmail.com>

R=rsc, agl1
CC=golang-dev
https://golang.org/cl/4331054
2011-04-05 10:59:10 -04:00
Rob Pike
80c5ef9f31 os: fix windows build
R=brainman
CC=golang-dev
https://golang.org/cl/4308047
2011-04-04 23:57:08 -07:00
Rob Pike
8a90fd3c72 os: New Open API.
We replace the current Open with:
OpenFile(name, flag, perm) // same as old Open
Open(name) // same as old Open(name, O_RDONLY, 0)
Create(name) // same as old Open(name, O_RDWR|O_TRUNC|O_CREAT, 0666)

This CL includes a gofix module and full code updates: all.bash passes.
(There may be a few comments I missed.)

The interesting packages are:
        gofix
        os
Everything else is automatically generated except for hand tweaks to:
        src/pkg/io/ioutil/ioutil.go
        src/pkg/io/ioutil/tempfile.go
        src/pkg/crypto/tls/generate_cert.go
        src/cmd/goyacc/goyacc.go
        src/cmd/goyacc/units.y

R=golang-dev, bradfitzwork, rsc, r2
CC=golang-dev
https://golang.org/cl/4357052
2011-04-04 23:42:14 -07:00
Andrew Gerrand
3ebc422ff8 tag weekly.2011-04-04
R=rsc
CC=golang-dev
https://golang.org/cl/4355052
2011-04-05 12:56:39 +10:00
Andrew Gerrand
51319b1125 weekly.2011-04-04
R=rsc
CC=golang-dev
https://golang.org/cl/4363043
2011-04-05 12:55:03 +10:00
Brad Fitzpatrick
6e4966eb7f http: ignore Transfer-Encoding on HEAD responses
Amazon S3 sends Transfer-Encoding "chunked"
on its 404 responses to HEAD requests for
missing objects.

We weren't ignoring the Transfer-Encoding
and were thus interpretting the subsequent
response headers as a chunk header from the
previous responses body (but a HEAD response
can't have a body)

R=rsc, adg
CC=golang-dev
https://golang.org/cl/4346050
2011-04-04 19:43:36 -07:00
Brad Fitzpatrick
243266f62e http: fix Transport connection re-use race
A connection shouldn't be made available
for re-use until its body has been consumed.

(except in the case of pipelining, which isn't
implemented yet)

This CL fixes some issues seen with heavy load
against Amazon S3.

Subtle implementation detail: to prevent a race
with the client requesting a new connection
before previous one is returned, we actually
have to call putIdleConnection _before_ we
return from the final Read/Close call on the
http.Response.Body.

R=rsc, adg
CC=golang-dev
https://golang.org/cl/4351048
2011-04-04 19:22:47 -07:00
Mikio Hara
f3ad899a2d net: fix typo
R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/4315049
2011-04-05 11:35:16 +10:00
Gustavo Niemeyer
94e60061eb filepath: new Abs function
R=golang-dev, rsc1, peterGo, bsiegert, r, mattn
CC=golang-dev
https://golang.org/cl/4271057
2011-04-04 18:29:24 -07:00
Brad Fitzpatrick
7c9c4fc3a1 http: fix hanging bug with HEAD responses
The transport readLoop was waiting forever for the client to
read the non-existent body before proceeding to read the next
request.

R=rsc
CC=golang-dev
https://golang.org/cl/4357051
2011-04-04 16:58:11 -07:00
Brad Fitzpatrick
2be13a80c7 os: add Seek whence constants
R=r, r2, rsc1, rsc, jacek.masiulaniec
CC=golang-dev
https://golang.org/cl/4344062
2011-04-04 13:53:52 -07:00
Russ Cox
d3ca620baf gotest: fix build
TBR=r
CC=golang-dev
https://golang.org/cl/4351047
2011-04-04 16:35:40 -04:00
Rob Pike
60c4c3464b path/filepath.Glob: add an error return.
The error will only occur for invalid patterns, but without this
error path there is no way to know that Glob has failed due to
an invalid pattern.

R=rsc
CC=golang-dev
https://golang.org/cl/4346044
2011-04-04 13:09:34 -07:00
Evan Shaw
06ee80d6eb bufio: Write and WriteString cleanup
Write never writes less than the buffer size and WriteString takes advantage
of the copy built-in to improve write efficiency.

R=rsc, ality, rog
CC=golang-dev
https://golang.org/cl/4344060
2011-04-04 15:57:10 -04:00
Matt Jones
5fd0a74987 http: use upper case hex in URL escaping
According to RFC 3986: "For consistency, URI producers
and normalizers should use uppercase hexadecimal digits
for all percent-encodings."  Using lower case characters
makes it incompatible with Google APIs when signing OAuth requests.

R=golang-dev, rsc1, rsc
CC=golang-dev
https://golang.org/cl/4352044
2011-04-04 15:49:49 -04:00
Russ Cox
7d43d00bf5 CONTRIBUTORS: add Matt Jones (Google CLA)
R=golang-dev, r2
CC=golang-dev, mrjones
https://golang.org/cl/4348048
2011-04-04 15:48:43 -04:00
Russ Cox
36c009d465 codereview: only retry on HTTP 500 error
R=r
CC=golang-dev
https://golang.org/cl/4353047
2011-04-04 15:47:32 -04:00
Albert Strasheim
492039ae7f os: Fix MkdirAll("/thisdoesnotexist").
Fixes #1637.

R=rsc, rh, msolo
CC=golang-dev
https://golang.org/cl/4317049
2011-04-04 15:45:03 -04:00
Mikio Hara
5a59b9eba3 syscall: add BPF support for freebsd/386, freebsd/amd64
R=rsc
CC=golang-dev
https://golang.org/cl/4331050
2011-04-04 15:40:40 -04:00
Brad Fitzpatrick
cc40870f4b httptest: add NewTLSServer
Enables the use of https servers in tests.

R=agl, rsc, agl1
CC=golang-dev
https://golang.org/cl/4284063
2011-04-04 08:32:59 -07:00
Brad Fitzpatrick
a2bcd3814d http: make triv.go example compile again
Ideally we'd compile all example files during
the build, though.

Fixes #1660

R=r
CC=golang-dev
https://golang.org/cl/4358049
2011-04-04 08:10:26 -07:00
Andrew Gerrand
0f46aaf8b3 version.bash: strip changeset hash from 'hg tags' output
Fixes #1651.

R=rsc
CC=golang-dev
https://golang.org/cl/4300054
2011-04-04 10:06:09 +10:00
Andrey Mirtchovski
fbeaa869f6 path/filepath: add support for plan9
R=paulzhol, ality, r, fhs
CC=golang-dev
https://golang.org/cl/4316054
2011-04-03 09:11:41 -07:00
Andrey Mirtchovski
69819c2ea3 os: add a few missing plan9 errors
these were needed by packages in crypto/ and by io/ioutil

R=golang-dev, r
CC=golang-dev
https://golang.org/cl/4350047
2011-04-03 08:52:43 -07:00
Ian Lance Taylor
60cfb63bd4 Make.pkg: increase test timeout to 120 seconds.
R=r, peterGo
CC=golang-dev
https://golang.org/cl/4344053
2011-04-02 22:23:34 -07:00
Yuval Pavel Zholkover
c256f0a4b3 os: Plan 9 support.
R=rsc, ality, r, r2
CC=golang-dev
https://golang.org/cl/4149046
2011-04-02 14:28:58 -07:00
Yuval Pavel Zholkover
1cc4a5cd94 R=rsc, brainman, ality, r2, r
CC=golang-dev
https://golang.org/cl/3816043
2011-04-02 14:24:03 -07:00
Robert Griesemer
c42b3e21c3 go/parser: package name must not be the blank identifier
R=r, r2, rsc1
CC=golang-dev
https://golang.org/cl/4343045
2011-04-01 20:51:55 -07:00
Evan Shaw
7b40095e8c syscall: make Rawsyscall6 pass 6th arg on linux/386
Forgot this one in the previous CL

R=rsc, r
CC=golang-dev
https://golang.org/cl/4345043
2011-04-01 22:26:57 -04:00
Russ Cox
6865cc0e8e gc: avoid saying same error 3 times
R=ken2
CC=golang-dev
https://golang.org/cl/4316051
2011-04-01 20:52:38 -04:00
Evan Shaw
46137557c4 syscall: make Syscall6 pass 6th arg on linux/386
R=rsc
CC=golang-dev
https://golang.org/cl/4350043
2011-04-01 20:46:01 -04:00
Rob Pike
a78a25a16b path/filepath.Glob: don't drop known matches on error.
Fixes #1610.

R=rsc
CC=golang-dev
https://golang.org/cl/4355042
2011-04-01 09:58:05 -07:00
Anthony Starks
731786439c misc/notepadplus: add syntax and completion support for notepad++
R=golang-dev, adg, peterGo
CC=golang-dev
https://golang.org/cl/4274072
2011-04-01 14:44:57 +11:00
Alex Brainman
799be52b35 gotest: another attempt to make it run on Windows
R=golang-dev, rsc1
CC=golang-dev
https://golang.org/cl/4347041
2011-04-01 13:38:33 +11:00
Alex Brainman
6c651728d8 gotest: execute gomake properly on Windows
R=peterGo, rsc, Joe Poirier
CC=golang-dev
https://golang.org/cl/4280087
2011-04-01 10:10:15 +11:00
Ian Lance Taylor
554082d6b1 testing: add -test.timeout option.
Since Go code can deadlock, this lets a testsuite driver set a
time limit for the test to run.  This is simple but imperfect,
in that it only catches deadlocks in Go code, not in the
runtime scheduler.

R=r, rsc, iant2
CC=golang-dev
https://golang.org/cl/4326048
2011-03-31 15:27:51 -07:00
Rob Pike
3907031358 fmt: implement precs for %q.
Also fix a bug: precision was in terms of bytes; should be runes.
Fixes #1652.

R=rsc, bradfitzgo, r2, bradfitzwork
CC=golang-dev
https://golang.org/cl/4280086
2011-03-31 14:56:01 -07:00
Rob Pike
016a99f440 roadmap: remove description of implementation of garbage collector.
It was speculation.
Also replace one silly word with an English replacement.

R=golang-dev, bradfitzgo
CC=golang-dev
https://golang.org/cl/4339041
2011-03-31 13:13:04 -07:00
Brad Fitzpatrick
883048daab http: add Transport.MaxIdleConnsPerHost
R=rsc
CC=golang-dev
https://golang.org/cl/4280079
2011-03-31 12:58:50 -07:00
Alexey Borzenkov
10694c81b0 net, syscall: fix windows build
Fix resolv_windows.go to support recent DNS-lookup changes

R=brainman, rsc1, rsc
CC=golang-dev
https://golang.org/cl/4300045
2011-03-31 15:16:18 +11:00
Rob Pike
7d77e3117c gotest: another try at flags.
doc.go contains the details. The short story:
- command line is passed to the binary
- a new flag, -file, is needed to name files
- known flags have the "test." prefix added for convenience.
- gotest-specific flags are trimmed from the command line.

The effect should be that most existing uses are unaffected,
the ability to name files is still present, and it's nicer to use.
The downside is a lot more code in gotest.

Also allow a test to be called just Test.

R=rsc, niemeyer, rog, r2
CC=golang-dev
https://golang.org/cl/4307049
2011-03-30 21:14:49 -07:00
Russ Cox
5a7a074261 gopack: comment out debugging print
TBR=r
CC=golang-dev
https://golang.org/cl/4333048
2011-03-30 22:41:32 -04:00
Russ Cox
3d2e57a312 gopack: add P flag to remove prefix from filename information
R=r, r2
CC=golang-dev
https://golang.org/cl/4307047
2011-03-30 22:19:02 -04:00
Russ Cox
b66b22cdd4 fmt: remove uintptrGetter type checks
This will make the fmt code easier to gofix
when the new reflect interface is ready.

R=r
CC=golang-dev
https://golang.org/cl/4324043
2011-03-30 22:12:30 -04:00