Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Done by adding *RLock* variants of the Lock* methods and removing the file truncation. The two sets of methods rely the same code by dispatching to shared methods, only varying the lock type. The exception is RLocked(), which checks its own, separate boolean. All the lock operations share the same mutex, though, so any all operations can block each other. The docs have been updated to reflet that fact. Also fixed the Windows Unlock() docs to refer to UnlockFileEx() instead of syscall.LOCK_UN.
- Loading branch information
Showing
5 changed files
with
256 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.