Skip to content

Concurrent Bug Fixes

Compare
Choose a tag to compare
@djherbis djherbis released this 04 Feb 06:37
· 43 commits to master since this release

Please Update to this Version!

Important Bug Fixes:

  • sync.Cond.Wait was not being called atomically. A Broadcast() could occur between RUnlock and Wait() therefore causing the Reader to miss a Write/Close event. If it happened on a Close() it would cause the Reader to block indefinitely. This has been resolved by making the Wait call atomic with RUnlock.
  • Stream.Close() now obtains the Write lock such that Broadcast() from a close will only occur while a Reader is Waiting or before a ReadAt call. It's also now safe to call with Write() as the documentation suggested. Though this could lead to a failed Write (on a closed file), but this is always true when closing/writing concurrently.