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

NAME

6       explain_fopen_or_die - open file and report errors
7

SYNOPSIS

9       #include <libexplain/fopen.h>
10
11       FILE *explain_fopen_or_die(const char *pathname, const char *flags);
12

DESCRIPTION

14       The  explain_fopen_or_die()  function  opens the file whose name is the
15       string pointed to by pathname and associates a  stream  with  it.   See
16       fopen(3) for more information.
17
18       This is a quick and simple way for programs to constitently report file
19       open errors in a consistent and detailed fahion.
20

RETURN VALUE

22       Upon successful completion explain_fopen_or_die returns a FILE pointer.
23
24       If an error occurs, explain_fopen will be called to explain the  error,
25       which  will be printed onto stderr, and then the process will terminate
26       by calling exit(EXIT_FAILURE).
27

SEE ALSO

29       fopen(3)
30               stream open functions
31
32       explain_fopen(3)
33               explain fopen(3) errors
34
35       exit(2) terminate the calling process
36
38       libexplain version 1.4
39       Copyright (C) 2008 Peter Miller
40

AUTHOR

42       Written by Peter Miller <pmiller@opensource.org.au>
43
44
45
46                                                       explain_fopen_or_die(3)
Impressum