1explain_closedir_or_die(3) Library Functions Manual explain_closedir_or_die(3)
2
3
4

NAME

6       explain_closedir_or_die - close a directory and report errors
7

SYNOPSIS

9       #include <libexplain/closedir.h>
10       void explain_closedir_or_die(DIR *dir);
11

DESCRIPTION

13       The  explain_closedir_or_die  function  is used to call the closedir(3)
14       system call.  On failure an explanation  will  be  printed  to  stderr,
15       obtained  from  explain_closedir(3), and then the process terminates by
16       calling exit(EXIT_FAILURE).
17
18       This function is intended to be used in a fashion similar to  the  fol‐
19       lowing example:
20              explain_closedir_or_die(dir);
21
22       dir     The  dir,  exactly  as  to  be passed to the closedir(3) system
23               call.
24
25       Returns:
26               This function only returns on success.  On failure,  prints  an
27               explanation and exits.
28

SEE ALSO

30       closedir(3)
31               close a directory
32
33       explain_closedir(3)
34               explain closedir(3) errors
35
36       exit(2) terminate the calling process
37
39       libexplain version 0.40
40       Copyright (C) 2008 Peter Miller
41
42
43
44                                                    explain_closedir_or_die(3)
Impressum