tendermint/libs/autofile
Anton Kaliaev 5b1b1ea58a [libs/autofile] fix DATA RACE by removing openFile() call (#2539)
There's a time window after we call RotateFile() where autofile#index+1
does not exist. It will be created during the next call to Write(). BUT
if somebody calls NewReader() before Write(), it will fail with "open
  /tmp/wal#index+1/wal: no such file or directory"

We must create file (either by calling gr.Head.openFile() or directly)
during NewReader() to ensure read calls succeed.

Closes #2538
2018-10-04 17:57:59 -04:00
..
cmd libs: Call Flush() before rename #2428 (#2439) 2018-09-25 13:22:45 +02:00
README.md mv tmlibs files to libs dir 2018-07-01 22:36:03 -04:00
autofile.go libs: Handle SIGHUP explicitly inside autofile (#2480) 2018-09-25 12:43:28 +02:00
autofile_test.go libs: Handle SIGHUP explicitly inside autofile (#2480) 2018-09-25 12:43:28 +02:00
group.go [libs/autofile] fix DATA RACE by removing openFile() call (#2539) 2018-10-04 17:57:59 -04:00
group_test.go libs: Call Flush() before rename #2428 (#2439) 2018-09-25 13:22:45 +02:00

README.md

go-autofile