diff options
author | ru <ru@FreeBSD.org> | 2005-01-21 08:36:40 +0000 |
---|---|---|
committer | ru <ru@FreeBSD.org> | 2005-01-21 08:36:40 +0000 |
commit | 7a3e657c56eb965857c0eaa67dfd6280cc69f93b (patch) | |
tree | 36796da3893db6597f28e6ae2ca01d40b60b73cb /share/man/man9/g_event.9 | |
parent | e892f32ba81eb2390a9e34d8cea91ef6c95ce340 (diff) | |
download | FreeBSD-src-7a3e657c56eb965857c0eaa67dfd6280cc69f93b.zip FreeBSD-src-7a3e657c56eb965857c0eaa67dfd6280cc69f93b.tar.gz |
Sort sections.
Diffstat (limited to 'share/man/man9/g_event.9')
-rw-r--r-- | share/man/man9/g_event.9 | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/share/man/man9/g_event.9 b/share/man/man9/g_event.9 index 0cb574d..380caa8 100644 --- a/share/man/man9/g_event.9 +++ b/share/man/man9/g_event.9 @@ -130,6 +130,21 @@ and .Fn g_waitfor_event functions return 0 if successful; otherwise an error code is returned. +.Sh EXAMPLES +Example of a function called from the event queue. +.Bd -literal -offset indent +void +example_event(void *arg, int flag) +{ + + if (flag == EV_CANCEL) { + printf("Event with argument %p canceled.\\n", arg); + return; + } + + printf("Event with argument %p called.\\n", arg); +} +.Ed .Sh ERRORS Possible errors for the .Fn g_post_event @@ -156,21 +171,6 @@ argument was set to .Dv M_NOWAIT and there was insufficient memory. .El -.Sh EXAMPLES -Example of a function called from the event queue. -.Bd -literal -offset indent -void -example_event(void *arg, int flag) -{ - - if (flag == EV_CANCEL) { - printf("Event with argument %p canceled.\\n", arg); - return; - } - - printf("Event with argument %p called.\\n", arg); -} -.Ed .Sh SEE ALSO .Xr geom 4 , .Xr DECLARE_GEOM_CLASS 9 , |