GRASS 8 Programmer's Manual 8.6.0dev(2026)-c83afef6d3
Loading...
Searching...
No Matches
fcntl.h
Go to the documentation of this file.
1/*!
2 * \file msvc/fcntl.h
3 *
4 * \brief Header file for msvc/fcntl.c
5 *
6 * SPDX-FileCopyrightText: 2025 GRASS Development Team
7 * SPDX-License-Identifier: GPL-2.0-or-later
8 *
9 * \author Huidae Cho
10 *
11 * \date 2025
12 */
13
14#ifndef GRASS_MSVC_FCNTL_H
15#define GRASS_MSVC_FCNTL_H
16
17#include <../ucrt/fcntl.h>
18
19#ifdef __cplusplus
20extern "C" {
21#endif
22
23/* these wrapper functions convert UN*X permission mode for MSVC */
24int __open(const char *, int, ...);
25int __creat(const char *, int);
26
27#ifdef __cplusplus
28}
29#endif
30
31#include <io.h>
32#define open __open
33#define creat __creat
34
35#define O_TMPFILE O_TEMPORARY
36#define O_ACCMODE (_O_RDONLY | _O_WRONLY | _O_RDWR)
37
38#endif
int __creat(const char *, int)
Definition fcntl.c:39
int __open(const char *, int,...)
Definition fcntl.c:21