Commit eeaa048c authored by Niels Möller's avatar Niels Möller
Browse files

Add reason argument to close_fd.

Rev: src/io.c:1.27
Rev: src/io.h:1.19
parent 86db2e21
......@@ -710,9 +710,9 @@ struct io_fd *io_write(struct io_backend *b,
/* Marks a file for closing, at the end of the current iteration.
* FIXME: Could be generalized for other fd:s than read-write fds. */
void close_fd(struct lsh_fd *fd)
void close_fd(struct lsh_fd *fd, int reason)
{
debug("Marking fd %d for closing.\n", fd->fd);
fd->close_reason = reason;
fd->close_now = 1;
}
......@@ -187,6 +187,7 @@ struct io_fd *io_write(struct io_backend *b,
UINT32 block_size,
struct close_callback *close_callback);
void close_fd(struct lsh_fd *fd);
void close_fd(struct lsh_fd *fd, int reason);
#endif /* LSH_IO_H_INCLUDED */
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment