]> xenbits.xensource.com Git - unikraft/libs/lwip.git/commitdiff
Import sendfile.h from musl
authorMihai Pogonaru <pogonarumihai@gmail.com>
Mon, 28 Oct 2019 23:40:01 +0000 (01:40 +0200)
committerCostin Lupu <costin.lup@gmail.com>
Tue, 29 Oct 2019 13:19:27 +0000 (15:19 +0200)
Copied as is from the official musl git mirror
git://git.musl-libc.org/musl, commit 06d4075a.

Signed-off-by: Mihai Pogonaru <pogonarumihai@gmail.com>
Reviewed-by: Costin Lupu <costin.lupu@cs.pub.ro>
musl-imported/include/sys/sendfile.h [new file with mode: 0644]

diff --git a/musl-imported/include/sys/sendfile.h b/musl-imported/include/sys/sendfile.h
new file mode 100644 (file)
index 0000000..e7570d8
--- /dev/null
@@ -0,0 +1,22 @@
+#ifndef _SYS_SENDFILE_H
+#define _SYS_SENDFILE_H
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#include <features.h>
+#include <unistd.h>
+
+ssize_t sendfile(int, int, off_t *, size_t);
+
+#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
+#define sendfile64 sendfile
+#define off64_t off_t
+#endif
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif