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

* src/io.c (finish_io_exception): New static object.

Rev: src/io.c:1.109
Rev: src/io.h:1.61
parent 5abff7df
......@@ -1655,8 +1655,11 @@ make_exc_finish_read_handler(struct lsh_fd *fd,
return &self->super;
}
struct exception finish_read_exception =
STATIC_EXCEPTION(EXC_FINISH_READ, "Finish i/o");
const struct exception finish_read_exception =
STATIC_EXCEPTION(EXC_FINISH_READ, "Stop reading");
const struct exception finish_io_exception =
STATIC_EXCEPTION(EXC_FINISH_IO, "Stop i/o");
struct exception *
make_io_exception(UINT32 type, struct lsh_fd *fd, int error, const char *msg)
......
......@@ -233,7 +233,8 @@ make_io_exception(UINT32 type, struct lsh_fd *fd, int error, const char *msg);
#define STATIC_IO_EXCEPTION(type, name) \
{ { STATIC_HEADER, (type), (name) }, NULL, 0}
extern struct exception finish_read_exception;
extern const struct exception finish_read_exception;
extern const struct exception finish_io_exception;
void init_backend(struct io_backend *b);
......@@ -325,8 +326,8 @@ struct lsh_fd *io_read(struct lsh_fd *fd,
struct close_callback *close_callback);
struct lsh_fd *io_write(struct lsh_fd *fd,
UINT32 block_size,
struct close_callback *close_callback);
UINT32 block_size,
struct close_callback *close_callback);
/* Marks a file for close, without touching the close_reason field. */
void kill_fd(struct lsh_fd *fd);
......
Supports Markdown
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