mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-29 10:18:30 +00:00
Another spin loop bug. On dropped network connections, console(8) can
also spin getting a 0 return from write(). (it's only testing for -1).
This commit is contained in:
parent
13666592ed
commit
1addd067e6
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=11583
@ -26,6 +26,13 @@
|
||||
+ (void)tcsetattr(0, TCSANOW, &o_tios);
|
||||
#else
|
||||
#if USE_TERMIO
|
||||
@@ -478,5 +478,5 @@
|
||||
|
||||
while (0 != iLen) {
|
||||
- if (-1 == (nr = write(fd, pcBuf, iLen))) {
|
||||
+ if (0 <= (nr = write(fd, pcBuf, iLen))) {
|
||||
c2cooked();
|
||||
fprintf(stderr, "%s: lost connection\n", progname);
|
||||
@@ -950,5 +950,5 @@
|
||||
iRem = iMax;
|
||||
i = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user