-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Instead use os.OpenFile (which doesn't check the file type though). This approach has the advantage that we can handle an mkfifo error in createListener (where it is possible to terminate the program). The worst case problem resulting of the fact that the file type is no longer checked is if the file is removed between the syscall.Mkfifo in createListener() and the os.Open() in recvInput(). In this case recvInpu() would constantly require CPU time as os.Open() no longer blocks. But this is (a) very unlikely and (b) requires the user to manually remove the file.
- Loading branch information
Showing
1 changed file
with
10 additions
and
26 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