diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/main.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -7,6 +7,7 @@ * (at your option) any later version. */ +#define _GNU_SOURCE #include <stdlib.h> #include <stdio.h> #include <ev.h> @@ -273,7 +274,7 @@ static int tip_client_head_hdr(struct tip_client *cli) return -1; } - if (posix_fallocate(cli->fd, 0, cli->content_len) < 0) { + if (fallocate(cli->fd, 0, 0, cli->content_len) < 0) { syslog(LOG_ERR, "failed to allocate room for file %s: %s", filename, strerror(errno)); return -1; |