Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
LSH
lsh
Commits
bf0c2043
Commit
bf0c2043
authored
Jun 14, 1999
by
Niels Möller
Browse files
* src/io.c (io_iter): Close fd:s that report POLLHUP.
Rev: src/io.c:1.63
parent
10c1563f
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/io.c
View file @
bf0c2043
...
...
@@ -112,6 +112,8 @@ int io_iter(struct io_backend *b)
*
fd_p
=
fd
->
next
;
continue
;
}
/* FIXME: nfds should probably include only fd:s that we are
* interested in reading or writing. */
nfds
++
;
fd_p
=
&
fd
->
next
;
}
...
...
@@ -206,7 +208,10 @@ int io_iter(struct io_backend *b)
else
if
(
fd
->
want_write
)
WRITE_FD
(
fd
);
else
werror
(
"io.c: poll said POLLHUP on an inactive fd.
\n
"
);
{
werror
(
"io.c: poll said POLLHUP on an inactive fd.
\n
"
);
close_fd
(
fd
,
CLOSE_EOF
);
}
continue
;
}
...
...
@@ -487,7 +492,7 @@ static void init_file(struct io_backend *b, struct lsh_fd *f, int fd)
f
->
close_callback
=
NULL
;
f
->
prepare
=
NULL
;
f
->
want_read
=
0
;
f
->
read
=
NULL
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment