init.sh: work around trap limitation of some shells
[pspp] / tests / test-pwrite.c
index 073f6a336c286d13d8463caa003030e80cf562a8..ef80eb2cd74e9eec31855997d178e051e1d1850e 100644 (file)
@@ -24,6 +24,7 @@ SIGNATURE_CHECK (pwrite, ssize_t, (int, const void *, size_t, off_t));
 #include <sys/types.h>
 #include <fcntl.h>
 #include <errno.h>
+#include <string.h>
 
 #include "macros.h"
 
@@ -69,7 +70,6 @@ main (void)
   ASSERT (close (fd) == 0);
 
   {
-    char read_buf[N];
     fd = open (file, O_RDONLY);
     ASSERT (0 <= fd);
     ASSERT (read (fd, buf, N) == N);