Remove blocking struct iop operation
The blocking I/O option makes no sense in the server, because it blocks the server process instead of the thread. In fact, it's been unused since Empire 2, except for one place, where it was used incorrectly, and got removed in the previous commit. Make I/O non-blocking in io_open() unconditionally. Remove IO_NBLOCK and io_noblocking().
This commit is contained in:
parent
70bc528d0d
commit
3805548b3e
3 changed files with 13 additions and 31 deletions
|
@ -82,8 +82,7 @@ player_new(int s)
|
|||
idle_timeout.tv_usec = 0 ;
|
||||
if (s >= 0) {
|
||||
/* real player, not dummy created by update and market update */
|
||||
lp->iop = io_open(s, IO_READ | IO_WRITE | IO_NBLOCK, IO_BUFSIZE,
|
||||
idle_timeout);
|
||||
lp->iop = io_open(s, IO_READ | IO_WRITE, IO_BUFSIZE, idle_timeout);
|
||||
if (!lp->iop) {
|
||||
free(lp);
|
||||
return NULL;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue