summaryrefslogtreecommitdiff
path: root/src/common/compat.h
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2014-07-16 13:58:55 +0200
committerNick Mathewson <nickm@torproject.org>2014-07-16 13:58:55 +0200
commit867f5e6a7602fe5cf54686aa04995eaabaea4c80 (patch)
tree3954fab482ffc83324ae53a7d252c5479ddc09b9 /src/common/compat.h
parent15e170e01b3f67325f952d0becda0438fa879907 (diff)
downloadtor-867f5e6a7602fe5cf54686aa04995eaabaea4c80.tar.gz
tor-867f5e6a7602fe5cf54686aa04995eaabaea4c80.zip
Add a tor_ftruncate to replace ftruncate.
(Windows doesn't have ftruncate, and some ftruncates do not move the file pointer to the start of the file.)
Diffstat (limited to 'src/common/compat.h')
-rw-r--r--src/common/compat.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/common/compat.h b/src/common/compat.h
index 296042fa50..852a432187 100644
--- a/src/common/compat.h
+++ b/src/common/compat.h
@@ -408,6 +408,7 @@ void tor_lockfile_unlock(tor_lockfile_t *lockfile);
off_t tor_fd_getpos(int fd);
int tor_fd_setpos(int fd, off_t pos);
int tor_fd_seekend(int fd);
+int tor_ftruncate(int fd);
#ifdef _WIN32
#define PATH_SEPARATOR "\\"