Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

encoding/xml: data race #11885

Closed
ianlancetaylor opened this issue Jul 27, 2015 · 1 comment
Closed

encoding/xml: data race #11885

ianlancetaylor opened this issue Jul 27, 2015 · 1 comment
Milestone

Comments

@ianlancetaylor
Copy link
Contributor

After https://golang.org/cl/12570 the race builders are failing fairly consistently with a data race in encoding/xml. Sample race:

WARNING: DATA RACE
Write by goroutine 20:
runtime.slicecopy()
/tmp/workdir/go/src/runtime/slice.go:110 +0x0
encoding/xml.(_parentStack).push()
/tmp/workdir/go/src/encoding/xml/marshal.go:959 +0x31c
encoding/xml.(_printer).marshalStruct()
/tmp/workdir/go/src/encoding/xml/marshal.go:877 +0x586
encoding/xml.(_printer).marshalValue()
/tmp/workdir/go/src/encoding/xml/marshal.go:576 +0x14c2
encoding/xml.(_Encoder).Encode()
/tmp/workdir/go/src/encoding/xml/marshal.go:153 +0xaf
encoding/xml.Marshal()
/tmp/workdir/go/src/encoding/xml/marshal.go:72 +0x213
encoding/xml.TestRace9796.func1()
/tmp/workdir/go/src/encoding/xml/marshal_test.go:1698 +0xbd

Previous read by goroutine 19:
encoding/xml.(_parentStack).trim()
/tmp/workdir/go/src/encoding/xml/marshal.go:944 +0x2a8
encoding/xml.(_printer).marshalStruct()
/tmp/workdir/go/src/encoding/xml/marshal.go:887 +0x1ce
encoding/xml.(_printer).marshalValue()
/tmp/workdir/go/src/encoding/xml/marshal.go:576 +0x14c2
encoding/xml.(_Encoder).Encode()
/tmp/workdir/go/src/encoding/xml/marshal.go:153 +0xaf
encoding/xml.Marshal()
/tmp/workdir/go/src/encoding/xml/marshal.go:72 +0x213
encoding/xml.TestRace9796.func1()
/tmp/workdir/go/src/encoding/xml/marshal_test.go:1698 +0xbd

Goroutine 20 (running) created at:
encoding/xml.TestRace9796()
/tmp/workdir/go/src/encoding/xml/marshal_test.go:1700 +0x96
testing.tRunner()
/tmp/workdir/go/src/testing/testing.go:456 +0xdc

Goroutine 19 (running) created at:
encoding/xml.TestRace9796()
/tmp/workdir/go/src/encoding/xml/marshal_test.go:1700 +0x96
testing.tRunner()
/tmp/workdir/go/src/testing/testing.go:456 +0xdc

@ianlancetaylor ianlancetaylor added this to the Go1.5 milestone Jul 27, 2015
@gopherbot
Copy link

CL https://golang.org/cl/12687 mentions this issue.

@rsc rsc closed this as completed in 765cea2 Jul 27, 2015
@golang golang locked and limited conversation to collaborators Aug 5, 2016
@rsc rsc removed their assignment Jun 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants