diff options
author | Audrius Butkevicius <audrius.butkevicius@gmail.com> | 2016-04-22 08:12:10 +0000 |
---|---|---|
committer | Jakob Borg <jakob@nym.se> | 2016-04-22 08:12:10 +0000 |
commit | 4aa6ecb122f5145f6b404f31088e877f459fc15e (patch) | |
tree | b6d451899347eb8c22533f34b178b2179b749b38 | |
parent | ccfcdf7f4885839ed72e8107baa058ad10f7d5b6 (diff) |
lib/model: Do not use WRONLY (ref #2584)
GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/2994
-rw-r--r-- | lib/model/sharedpullerstate.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/model/sharedpullerstate.go b/lib/model/sharedpullerstate.go index f079fdad51..eabcbd3e12 100644 --- a/lib/model/sharedpullerstate.go +++ b/lib/model/sharedpullerstate.go @@ -122,7 +122,8 @@ func (s *sharedPullerState) tempFile() (io.WriterAt, error) { } // Attempt to create the temp file - flags := os.O_WRONLY + // RDWR because of issue #2994. + flags := os.O_RDWR if s.reused == 0 { flags |= os.O_CREATE | os.O_EXCL } else { |