From 035b3e0b5db8be1444c6bc1cfc929d03c0fb5196 Mon Sep 17 00:00:00 2001 From: Martin Mares Date: Sat, 26 Feb 2011 23:45:18 +0100 Subject: [PATCH] Main: Renamed MFERR_xxx to BIO_ERR_xxx --- ucw/main-block.c | 6 +++--- ucw/mainloop.h | 12 ++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/ucw/main-block.c b/ucw/main-block.c index 918cb777..98c558e6 100644 --- a/ucw/main-block.c +++ b/ucw/main-block.c @@ -24,7 +24,7 @@ block_io_timer_expired(struct main_timer *tm) struct main_block_io *bio = tm->data; timer_del(&bio->timer); if (bio->error_handler) - bio->error_handler(bio, MFERR_TIMEOUT); + bio->error_handler(bio, BIO_ERR_TIMEOUT); } void @@ -55,7 +55,7 @@ block_io_read_handler(struct main_file *fi) if (l < 0) { if (errno != EINTR && errno != EAGAIN && bio->error_handler) - bio->error_handler(bio, MFERR_READ); + bio->error_handler(bio, BIO_ERR_READ); return 0; } else if (!l) @@ -81,7 +81,7 @@ block_io_write_handler(struct main_file *fi) if (l < 0) { if (errno != EINTR && errno != EAGAIN && bio->error_handler) - bio->error_handler(bio, MFERR_WRITE); + bio->error_handler(bio, BIO_ERR_WRITE); return 0; } bio->wpos += l; diff --git a/ucw/mainloop.h b/ucw/mainloop.h index 9ad3bed3..088d769e 100644 --- a/ucw/mainloop.h +++ b/ucw/mainloop.h @@ -272,7 +272,7 @@ void file_del(struct main_file *fi); * (except that it gets added and deleted at the right places), feel free * to adjust it from your handler functions by @block_io_set_timeout(). * When the timer expires, the error handler is automatically called with - * `MFERR_TIMEOUT`. + * `BIO_ERR_TIMEOUT`. ***/ /** The block I/O structure. **/ @@ -298,14 +298,14 @@ void block_io_del(struct main_block_io *bio); /** * Specifies when or why an error happened. This is passed to the error handler. * `errno` is still set to the original source of error. The only exception - * is `MFERR_TIMEOUT`, in which case `errno` is not set and the only possible + * is `BIO_ERR_TIMEOUT`, in which case `errno` is not set and the only possible * cause of it is timeout of the timer associated with the block_io * (see @block_io_set_timeout()). **/ enum block_io_err_cause { - MFERR_READ, - MFERR_WRITE, - MFERR_TIMEOUT + BIO_ERR_READ, + BIO_ERR_WRITE, + BIO_ERR_TIMEOUT }; /** @@ -338,7 +338,7 @@ void block_io_write(struct main_block_io *bio, void *buf, uns len); /** * Sets a timer for a file @bio. If the timer is not overwritten or disabled * until @expires_delta milliseconds, the file timeouts and error_handler() is called with - * <>. A value of `0` stops the timer. + * <>. A value of `0` stops the timer. * * Previous setting of the timeout on the same file will be overwritten. * -- 2.39.2