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

Subtle data race in GetCSV #3045

Closed
bep opened this Issue Feb 17, 2017 · 0 comments

Comments

Projects
None yet
1 participant
@bep
Member

bep commented Feb 17, 2017

WARNING: DATA RACE
Write at 0x00c4201f4a20 by goroutine 69:
  runtime.mapassign1()
      /usr/local/Cellar/go/1.7.4/libexec/src/runtime/hashmap.go:442 +0x0
  github.com/spf13/hugo/tpl/tplimpl.(*remoteLock).URLLock()
      /Users/bep/go/src/github.com/spf13/hugo/tpl/tplimpl/template_resources.go:50 +0x1bb
  github.com/spf13/hugo/tpl/tplimpl.resGetRemote()
      /Users/bep/go/src/github.com/spf13/hugo/tpl/tplimpl/template_resources.go:125 +0x1ba
  github.com/spf13/hugo/tpl/tplimpl.(*templateFuncster).resGetResource()
      /Users/bep/go/src/github.com/spf13/hugo/tpl/tplimpl/template_resources.go:172 +0x1c2
  github.com/spf13/hugo/tpl/tplimpl.(*templateFuncster).getCSV()
      /Users/bep/go/src/github.com/spf13/hugo/tpl/tplimpl/template_resources.go:233 +0x1c7
  github.com/spf13/hugo/tpl/tplimpl.TestGetCSVFailParse()
      /Users/bep/go/src/github.com/spf13/hugo/tpl/tplimpl/template_resources_test.go:297 +0x4ed
  testing.tRunner()
      /usr/local/C{ellar/go/1.7.4/libexec/src/testing/testing.go:610 +0xc9

Previous read at 0x00c4201f4a20 by goroutine 68:
  runtime.mapaccess1_faststr()
      /usr/local/Cellar/go/1.7.4/libexec/src/runtime/hashmap_fast.go:192 +0x0
  github.com/spf13/hugo/tpl/tplimpl.(*remoteLock).URLLock()
      /Users/bep/go/src/github.com/spf13/hugo/tpl/tplimpl/template_resources.go:53 +0xeb
  github.com/spf13/hugo/tpl/tplimpl.resGetRemote()
      /Users/bep/go/src/github.com/spf13/hugo/tpl/tplimpl/template_resources.go:125 +0x1ba
  github.com/spf13/hugo/tpl/tplimpl.(*templateFuncster).resGetResource()
      /Users/bep/go/src/github.com/spf13/hugo/tpl/tplimpl/template_resources.go:172 +0x1c2
  github.com/spf13/hugo/tpl/tplimpl.(*templateFuncster).getCSV()
      /Users/bep/go/src/github.com/spf13/hugo/tpl/tplimpl/template_resources.go:233 +0x1c7
  github.com/spf13/hugo/tpl/tplimpl.TestGetCSVFailParseSep()
      /Users/bep/go/src/github.com/spf13/hugo/tpl/tplimpl/template_resources_test.go:265 +0x4ed
  testing.tRunner()
      /usr/local/Cellar/go/1.7.4/libexec/src/testing/testing.go:610 +0xc9

bep added a commit to bep/hugo that referenced this issue Feb 17, 2017

@bep bep closed this in 4b3ca38 Feb 17, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment