diff options
author | Jeremy Harris <jgh@wizmail.org> | 2017-10-01 15:36:32 +0100 |
---|---|---|
committer | Jeremy Harris <jgh@wizmail.org> | 2017-10-01 15:36:32 +0100 |
commit | d5b80e59458182b2d557a929a18cb8c70cd56b68 (patch) | |
tree | 1707bd0710e1a37ef5872533ab531dd22b138d6d /src/OS/os.c-FreeBSD | |
parent | d5c0d8c9374623620844d539d4810da63e9abca1 (diff) | |
parent | e924c08b7d031b712013a7a897e2d430b302fe6c (diff) |
Merge branch 'master' into 4.next
Diffstat (limited to 'src/OS/os.c-FreeBSD')
-rw-r--r-- | src/OS/os.c-FreeBSD | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/OS/os.c-FreeBSD b/src/OS/os.c-FreeBSD new file mode 100644 index 000000000..715a9ed42 --- /dev/null +++ b/src/OS/os.c-FreeBSD @@ -0,0 +1,24 @@ +/************************************************* +* Exim - an Internet mail transport agent * +*************************************************/ + +/* Copyright (c) Jeremy Harris 2017 */ +/* See the file NOTICE for conditions of use and distribution. */ + +/* FreeBSD-specific code. This is concatenated onto the generic +src/os.c file. */ + + +/************* +* Sendfile * +*************/ + +ssize_t +os_sendfile(int out, int in, off_t * off, size_t cnt) +{ +off_t written; +return sendfile(in, out, *off, cnt, NULL, &written, 0) < 0 + ? (ssize_t) -1 : (ssize_t) written; +} + +/* End of os.c-Linux */ |