summaryrefslogtreecommitdiffstats
path: root/src/rccxml.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/rccxml.c')
-rw-r--r--src/rccxml.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/rccxml.c b/src/rccxml.c
index 1db5788..cc07fa9 100644
--- a/src/rccxml.c
+++ b/src/rccxml.c
@@ -18,9 +18,13 @@
*/
#include <stdio.h>
-#include <string.h>
#include <stdarg.h>
+#include <string.h>
+#ifdef HAVE_STRINGS_H
+# include <strings.h>
+#endif /* HAVE_STRINGS_H */
+
#include "../config.h"
#ifdef HAVE_UNISTD_H
@@ -467,7 +471,10 @@ clear:
}
xmlFreeDoc(doc);
}
+
+#ifdef HAVE_FSYNC
fsync(fd);
+#endif /* HAVE_FSYNC */
#if defined(HAVE_FLOCK)
flock(fd, LOCK_UN);