TacOS
0.2
|
File control operations. Plus de détails...
#include <sys/cdefs.h>
Aller au code source de ce fichier.
Macros | |
#define | O_ACCMODE 00000003 |
#define | O_RDONLY 00000000 |
#define | O_WRONLY 00000001 |
#define | O_RDWR 00000002 |
#define | O_CREAT 00000100 |
#define | O_EXCL 00000200 /* not fcntl */ |
#define | O_NOCTTY 00000400 /* not fcntl */ |
#define | O_TRUNC 00001000 |
#define | O_APPEND 00002000 |
#define | O_NONBLOCK 00004000 |
#define | O_SYNC 00010000 |
#define | FASYNC 00020000 /* fcntl, for BSD compatibility */ |
#define | O_DIRECT 00040000 |
#define | O_DIRECTORY 00200000 |
#define | O_NOFOLLOW 00400000 |
#define | O_NOATIME 01000000 |
#define | O_CLOEXEC 02000000 |
#define | F_SETFL 4 |
#define | F_GETFL 5 |
Fonctions | |
int | open (const char *pathname, int flags) |
int | close (int id) |
int | fcntl (int fd, unsigned int request, void *data) |
Copyright (C) 2010, 2011, 2012 - TacOS developers.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details at http://www.gnu.org/copyleft/gpl.html
You should have received a copy of the GNU General Public License along with this program; if not, see http://www.gnu.org/licenses.
#define O_ACCMODE 00000003 |
Access mode mask.
#define O_APPEND 00002000 |
Ajoute en fin de fichier.
#define O_CLOEXEC 02000000 |
set close_on_exec
#define O_CREAT 00000100 |
Create file if non-existant.
#define O_DIRECT 00040000 |
direct disk access hint
#define O_DIRECTORY 00200000 |
must be a directory
#define O_NOFOLLOW 00400000 |
don't follow links
#define O_NONBLOCK 00004000 |
Le read ne sera pas bloquant.
#define O_RDONLY 00000000 |
Open file for read only access.
#define O_RDWR 00000002 |
Open file for both reading and writing.
#define O_SYNC 00010000 |
Appel à write bloquant tant que les données ne sont pas écrites physiquement sur le disque.
#define O_TRUNC 00001000 |
Tronque le fichier à une longueur nulle.
#define O_WRONLY 00000001 |
Open file for write only access.
int close | ( | int | id | ) |
Ferme un fichier ouvert.
id | descripteur du fichier. |
int fcntl | ( | int | fd, |
unsigned int | request, | ||
void * | data | ||
) |
Manipulation d'un descripteur de fichier.
fd | descripteur du fichier. |
request | action à faire. |
data | les arguments nécessaires à l'action. |
int open | ( | const char * | pathname, |
int | flags | ||
) |
Ouvrir un fichier ou un périphérique.
pathname | Chemin du fichier. |
flags | Flags pour indiquer le mode d'ouverture. |