From 554d51b833eb2ed17c9d07a8362c2dcd565139f9 Mon Sep 17 00:00:00 2001
From: root read
(2) returni
EAGAIN
is far preferable to a program hanging until some data arrives.
If you cannot run the fd in non-blocking mode (for example you should not play around with an Xlib connection), then you have to seperately re-test -wether a file descriptor is really ready with a known-to-be good interface +whether a file descriptor is really ready with a known-to-be good interface such as poll (fortunately in our Xlib example, Xlib already does this on its own, so its quite safe to use).
Libev can be compiled with a variety of options, the most fundemantal is
-EV_MULTIPLICITY
. This option determines wether (most) functions and
+EV_MULTIPLICITY
. This option determines whether (most) functions and
callbacks have an initial struct ev_loop *
argument.
To make it easier to write programs that cope with either variant, the following macros are defined:
@@ -1874,7 +1874,7 @@ loop, if multiple loops are supported ("ev loop default").Example: Declare and initialise a check watcher, utilising the above -macros so it will work regardless of wether multiple loops are supported +macros so it will work regardless of whether multiple loops are supported or not.
static void check_cb (EV_P_ ev_timer *w, int revents) diff --git a/ev.pod b/ev.pod index be4196a..9ca14da 100644 --- a/ev.pod +++ b/ev.pod @@ -885,7 +885,7 @@ Cis far preferable to a program hanging until some data arrives. If you cannot run the fd in non-blocking mode (for example you should not play around with an Xlib connection), then you have to seperately re-test -wether a file descriptor is really ready with a known-to-be good interface +whether a file descriptor is really ready with a known-to-be good interface such as poll (fortunately in our Xlib example, Xlib already does this on its own, so its quite safe to use). @@ -1846,7 +1846,7 @@ the constructor. =head1 MACRO MAGIC Libev can be compiled with a variety of options, the most fundemantal is -C . This option determines wether (most) functions and +C . This option determines whether (most) functions and callbacks have an initial C argument. To make it easier to write programs that cope with either variant, the @@ -1890,7 +1890,7 @@ loop, if multiple loops are supported ("ev loop default"). =back Example: Declare and initialise a check watcher, utilising the above -macros so it will work regardless of wether multiple loops are supported +macros so it will work regardless of whether multiple loops are supported or not. static void -- cgit v1.2.3