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

NAME

6       explain_open_or_die - open file and report errors
7

SYNOPSIS

9       #include <fcntl.h>
10       #include <libexplain/open.h>
11
12       int explain_open_or_die(const char *pathname, int flags, int mode);
13

DESCRIPTION

15       Given a pathname for a file, open() returns a file descriptor, a small,
16       non‐negative integer for  use  in  subsequent  system  calls  (read(2),
17       write(2), lseek(2), fcntl(2), etc.).  The file descriptor returned by a
18       successful call will be the lowest‐numbered file  descriptor  not  cur‐
19       rently open for the process.  See open(2) for more information.
20

RETURN VALUE

22       On success, the new file descriptor is returned.
23
24       On  error,  a description of the error is obtained via explain_open(3),
25       and printed on stderr.  The process is the terminated via a call to the
26       exit(EXIT_FAILURE) function.
27
29       libexplain version 1.4
30       Copyright (C) 2008 Peter Miller
31

AUTHOR

33       Written by Peter Miller <pmiller@opensource.org.au>
34
35
36
37                                                        explain_open_or_die(3)
Impressum