diff options
author | Santiago M. Mola <santi@mola.io> | 2017-06-27 17:45:29 +0200 |
---|---|---|
committer | Santiago M. Mola <santi@mola.io> | 2017-06-27 17:45:47 +0200 |
commit | c9f5acc2d10ef8c20194ce25bffb1e204b18bfdf (patch) | |
tree | f954b632f20c8bcb0c5b9358b0c0500340a4eaa6 /storage/filesystem | |
parent | 2d02297a9156390d1a23584bd9d9833c65998f40 (diff) | |
download | go-git-c9f5acc2d10ef8c20194ce25bffb1e204b18bfdf.tar.gz |
fix race on packfile writer
Diffstat (limited to 'storage/filesystem')
-rw-r--r-- | storage/filesystem/internal/dotgit/writers.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/storage/filesystem/internal/dotgit/writers.go b/storage/filesystem/internal/dotgit/writers.go index e0a41a8..531259b 100644 --- a/storage/filesystem/internal/dotgit/writers.go +++ b/storage/filesystem/internal/dotgit/writers.go @@ -236,7 +236,7 @@ func (s *syncedReader) Seek(offset int64, whence int) (int64, error) { } p, err := s.r.Seek(offset, whence) - s.read = uint64(p) + atomic.StoreUint64(&s.read, uint64(p)) return p, err } |