1explain_timerfd_create_or_diLei(b3r)ary Functions Maenxupallain_timerfd_create_or_die(3)
2
3
4

NAME

6       explain_timerfd_create_or_die  -  create  file  descriptor  timers  and
7       report errors
8

SYNOPSIS

10       #include <libexplain/timerfd_create.h>
11       int explain_timerfd_create_or_die(int clockid, int flags);
12       int explain_timerfd_create_on_error(int clockid, int flags);
13

DESCRIPTION

15       The  explain_timerfd_create_or_die  function  is  used  to   call   the
16       timerfd_create(2)  system  call.  On  failure  an  explanation  will be
17       printed to stderr, obtained from  the  explain_timerfd_create(3)  func‐
18       tion, and then the process terminates by calling exit(EXIT_FAILURE).
19
20       The  explain_timerfd_create_on_error  function  is  used  to  call  the
21       timerfd_create(2) system  call.  On  failure  an  explanation  will  be
22       printed  to  stderr,  obtained from the explain_timerfd_create(3) func‐
23       tion, but still returns to the caller.
24
25       clockid The clockid, exactly as to be passed to  the  timerfd_create(2)
26               system call.
27
28       flags   The  flags,  exactly  as  to be passed to the timerfd_create(2)
29               system call.
30

RETURN VALUE

32       The explain_timerfd_create_or_die function only returns on success, see
33       timerfd_create(2)  for more information. On failure, prints an explana‐
34       tion and exits, it does not return.
35
36       The explain_timerfd_create_on_error function always returns  the  value
37       return by the wrapped timerfd_create(2) system call.
38

EXAMPLE

40       The  explain_timerfd_create_or_die function is intended to be used in a
41       fashion similar to the following example:
42              int result = explain_timerfd_create_or_die(clockid, flags);
43

SEE ALSO

45       timerfd_create(2)
46               timers that notify via file descriptors
47
48       explain_timerfd_create(3)
49               explain timerfd_create(2) errors
50
51       exit(2) terminate the calling process
52
54       libexplain version 1.4
55       Copyright (C) 2009 Peter Miller
56
57
58
59                                              explain_timerfd_create_or_die(3)
Impressum