µOS++ IIIe Reference 7.0.0
The third edition of µOS++, a POSIX inspired open source framework, written in C++
Loading...
Searching...
No Matches
uio.h
Go to the documentation of this file.
1/*
2 * This file is part of the µOS++ distribution.
3 * (https://github.com/micro-os-plus)
4 * Copyright (c) 2015-2023 Liviu Ionescu. All rights reserved.
5 *
6 * Permission to use, copy, modify, and/or distribute this software
7 * for any purpose is hereby granted, under the terms of the MIT license.
8 *
9 * If a copy of the license was not distributed with this file, it can
10 * be obtained from https://opensource.org/licenses/mit/.
11 */
12
13#ifndef POSIX_IO_SYS_UIO_H_
14#define POSIX_IO_SYS_UIO_H_
15
16// ----------------------------------------------------------------------------
17
18#include <unistd.h>
19
20#if defined(_POSIX_VERSION)
21
22#pragma GCC diagnostic push
23#if defined(__clang__)
24#pragma clang diagnostic ignored "-Wgnu-include-next"
25#endif
26#include_next <sys/uio.h>
27#pragma GCC diagnostic pop
28
29#else
30
31#include <sys/types.h>
32
33#ifdef __cplusplus
34extern "C"
35{
36#endif
37
38// ----------------------------------------------------------------------------
39
40 struct iovec
41 {
42 void* iov_base; // Base address of a memory region for input or output.
43 size_t iov_len; // The size of the memory pointed to by iov_base.
44 };
45
46 ssize_t
47 writev (int fildes, const struct iovec* iov, int iovcnt);
48
49// ----------------------------------------------------------------------------
50
51#ifdef __cplusplus
52}
53#endif
54
55#endif /* defined(_POSIX_VERSION) */
56
57#endif /* POSIX_IO_SYS_UIO_H_ */
Definition uio.h:41
void * iov_base
Definition uio.h:42
size_t iov_len
Definition uio.h:43
ssize_t writev(int fildes, const struct iovec *iov, int iovcnt)