Путеводитель по Руководству Linux

  User  |  Syst  |  Libr  |  Device  |  Files  |  Other  |  Admin  |  Head  |



   open    ( 2 )

открыть и, возможно, создать файл (open and possibly create a file)

  Name  |    Synopsis    |  Description  |  Return value  |  Error  |  Versions  |  Conforming to  |  Note  |  Bugs  |  See also  |

Синопсис (Synopsis)

#include <fcntl.h>

int open(const char *pathname, int flags); int open(const char *pathname, int flags, mode_t mode);

int creat(const char *pathname, mode_t mode);

int openat(int dirfd, const char *pathname, int flags); int openat(int dirfd, const char *pathname, int flags, mode_t mode);

/* Documented separately, in openat2(2): */ int openat2(int dirfd, const char *pathname, const struct open_how *how, size_t size);

Feature Test Macro Requirements for glibc (see feature_test_macros(7)):

openat(): Since glibc 2.10: _POSIX_C_SOURCE >= 200809L Before glibc 2.10: _ATFILE_SOURCE