Blob Blame History Raw
commit bafef98ef7f26099fd394822aa6bad395a666d0c
Author: Felix Schwarz <felix.schwarz@oss.schwarz.eu>
Date:   Sun Nov 5 11:48:16 2023 +0100

    include unistd.h in _chunker.c
    
    With Python 3.13, Python.h no longer includes the <unistd.h> standard header file:
    https://docs.python.org/3.13/whatsnew/3.13.html#id8

diff --git a/src/borg/_chunker.c b/src/borg/_chunker.c
index dd141e87..e5d9b54f 100644
--- a/src/borg/_chunker.c
+++ b/src/borg/_chunker.c
@@ -1,5 +1,8 @@
 #include <Python.h>
 #include <fcntl.h>
+#if !defined(_MSC_VER)
+#   include <unistd.h>
+#endif
 
 /* Cyclic polynomial / buzhash