This lets the test pass on PPC64 GNU/Linux, which uses a much
larger page size and thus uses more memory to hold blocks
allocated for memory profiling.
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/6048054
The reverseproxy test depended on the behavior of
runtime.NumGoroutines(), which makes no guarantee when
goroutines are reaped. Instead, modify the flushLoop()
to invoke a callback when it returns, so the exit
from the loop can be tested, instead of the number
of gorountines running.
R=bradfitz
CC=golang-dev
https://golang.org/cl/6068046
Clean up the flow of control.
Fix the TODO for handling <html> tags.
Add a case to ignore doctype declarations.
Pass one additional test.
R=nigeltao
CC=golang-dev
https://golang.org/cl/6072047
syscall.Exit would originally kill only the calling
Go proc, leaving behind other procs in the
same group. This change makes syscall.Exit call
runtime·exit, which due to CL
https://golang.org/cl/5617048
will cleanly exit all the Go procs in the group.
R=golang-dev, rsc, rminnich, remyoudompheng, ality, john
CC=golang-dev, mirtchovski
https://golang.org/cl/6036051
This method will allow us to be explicit about what we're doing when
we insert an implied token, and avoid repeating the logic involved in
multiple places.
R=nigeltao
CC=golang-dev
https://golang.org/cl/6060048
When FlushInterval is specified on ReverseProxy, the ResponseWriter is
wrapped with a maxLatencyWriter that periodically flushes in a
goroutine. That goroutine was not being cleaned up at the end of the
request. This resulted in a panic when Flush() was being called on a
ResponseWriter that was closed.
The code was updated to always send the done message to the flushLoop()
goroutine after copying the body. Futhermore, the code was refactored to
allow the test to verify the maxLatencyWriter behavior.
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/6033043
Add a case to ignore doctype tokens.
Clean up the flow of control to more clearly match the spec.
Pass one more test.
R=nigeltao
CC=golang-dev
https://golang.org/cl/6062047
Add case for doctype tokens (which are ignored).
This CL does not change the status of any tests.
R=golang-dev, nigeltao
CC=golang-dev
https://golang.org/cl/6061047
Don't require the home directory to exist. Just check
that it returns something.
Fixes#3531
R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/6056045
Docstrings were not being set for the wrapper
functions returned by the hgcommand decorator.
R=golang-dev, minux.ma, rsc
CC=golang-dev
https://golang.org/cl/6059043
Currently, the html package only runs a limited subset of the tests
in the testdata directory. This tends to limit development of the
parser to fixing the bug that causes the first failing test.
This CL gives it the ability to run all the tests and produce a
log showing the status of each test. (It does it when tests are run with
'go test --update-logs') The status is listed as PASS, FAIL, or PARSE
(PARSE means that parsing produced the correct tree, but rendering and
re-parsing does not produce the same tree).
When 'go test' is run without --update-logs, it runs the tests marked
'PASS' in the logs (and the parsing portion of the tests marked 'PARSE').
Thus it will fail if there has been a regression since the last
time the logs were updated.
My goal for this CL is to allow develoment of the html package to
be less test-driven, while still having the advantages of regression
tests. In other words, one can work on any portion of the parser
and quickly see whether he is breaking things or improving them.
Current statistics of the tests:
$ grep ^PASS *.log|wc -l
1017
$ grep ^PARSE *.log|wc -l
46
$ grep ^FAIL *.log|wc -l
181
R=nigeltao
CC=golang-dev
https://golang.org/cl/6031049
This change comes from CL 5536043,
created by Andrey Mirtchovski. His
description follows:
"The plan9 exec child handler does not manage
dup-ed fds from the parent correctly: when a
dup-ed file descriptor appears in the child's fd
list it is closed when first encountered and then
subsequent attempt to dup it later in Pass 2 fails,
resulting in 'fork/exec: fd out of range or not
open'."
R=golang-dev, rminnich, ality
CC=golang-dev, mirtchovski, rsc
https://golang.org/cl/6009046
Update runtime defs for openbsd. Add struct __tfork, which will be
needed by an upcoming change.
R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/6007050
Fixes#3495.
I adapted fmt.TestCountMallocs to fix the
existing tests. As the resulting tests did not
appear to belong to either itoa or ftoa I moved
them into their own file.
R=bradfitz, fullung
CC=golang-dev
https://golang.org/cl/5985072
When SNI based certificate selection is enabled, we previously used
the default private key even if we selected a non-default certificate.
Fixes#3367.
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/5987058
It's a common error to reference unexported field names in templates,
especially for newcomers. This catches the error at parse time rather than
execute time so the rare few who check errors will notice right away.
These were always an error, so the net behavior is unchanged.
Should break no existing code, just identify the error earlier.
R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/6009048
adg removed some now-unwanted fields in Package a while ago,
but there are still datastore entities with those fields,
so we must explicitly check for ErrFieldMismatch and ignore it.
R=golang-dev, rsc
CC=adg, golang-dev
https://golang.org/cl/6007043
below do not support '.
This makes package html consistent with package text/template's
HTMLEscape function.
Fixes#3489.
R=rsc, mikesamuel, dsymonds
CC=golang-dev
https://golang.org/cl/5992071
crypto/tls is tested, in part, by replaying recorded TLS connections
and checking that the bytes sent by the Go code haven't changed.
Previously we used GnuTLS's debug output and extracted the bytes of
the TLS connection using a Python script. That wasn't great, and I
think GnuTLS removed that level of debugging in a more current
release.
This change records the connection with Go code and adds a test for
ECDHE-AES clients generating using this method.
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/5988048
For completeness, we also expose the Canonical Combining Class of a rune.
This does not increase the data size.
R=r
CC=golang-dev
https://golang.org/cl/5931043
Update the threxit and thrsleep syscalls to match the ABI of the
OpenBSD 5.1 kernel. These changes are backwards compatible with
older kernels.
Fixes#3311.
R=golang-dev, rsc, devon.odell
CC=golang-dev
https://golang.org/cl/5777079