# Nick (trying to get tests to work)
AUTOMAKE_OPTIONS = serial-tests
-XFAIL_TESTS = src/test/iobtree_1 src/test/bit_1 src/test/mem_1 src/test/bucket_1 src/test/str_1
+XFAIL_TESTS = src/test/iobtree_1 src/test/bit_1 src/test/bucket_1 src/test/str_1
DISABLE_HARD_ERRORS = 1
#### THINGS AFTER THIS LINE WILL BE REMOVED PRIOR TO DISTRIBUTION ####
} else {
assert(!CRASH);
lseek(fd, pos, SEEK_SET);
- ftruncate(fd, fsize);
+ if (ftruncate(fd, fsize)) {} /* WUR; so pedantic */
return 0;
}
} else if (errno != EFBIG) {
assert(!CRASH);
lseek(fd, pos, SEEK_SET);
- ftruncate(fd, fsize);
+ if (ftruncate(fd, fsize)) {} /* WUR; so pedantic */
return 0;
}
} else {
assert(!CRASH);
lseek(fd, pos, SEEK_SET);
- ftruncate(fd, fsize);
+ if (ftruncate(fd, fsize)) {} /* WUR; so pedantic */
return 0;
}
}
} else if ((fsize < 2147483647)) {
assert(!CRASH);
lseek(fd, pos, SEEK_SET);
- ftruncate(fd, fsize);
+ if (ftruncate(fd, fsize)) {} /* WUR; so pedantic */
return 0;
}
} else {
assert(!CRASH);
lseek(fd, pos, SEEK_SET);
- ftruncate(fd, fsize);
+ if (ftruncate(fd, fsize)) {} /* WUR; so pedantic */
return 0;
}
}
char pad; \
type align; \
} s; \
- return ((unsigned int) &s.align) - ((unsigned int) &s.pad); \
+ /*return ((unsigned int) &s.align) - ((unsigned int) &s.pad);*/ \
+ return (unsigned int) ((char *) &s.align - &s.pad); \
}
/* this macro returns what should be the maximum alignment on this platform */
#ifndef _FILE_OFFSET_BITS
#define _FILE_OFFSET_BITS 64 /* large file support */
#endif
-#ifndef _BSD_SOURCE
-#define _BSD_SOURCE /* for snprintf */
+#ifndef _DEFAULT_SOURCE
+#define _DEFAULT_SOURCE /* for snprintf */
#endif
#ifndef _POSIX_SOURCE
#define _POSIX_SOURCE /* for lots of stuff */
union {
unsigned int unum;
- unsigned char uchar[1];
+ unsigned char uchar[/*1*/sizeof(int)];
} u;
/* ensure that we aren't testing from a file */
fprintf(stderr, "failed to add to treceval results\n");
free(results);
free(querynum);
- free(docno);
+ /* no; aux_buf shouldn't be freed: free(docno); */
free(query);
mlparse_wrap_delete(parser);
return 0;
}
/* read construction file */
- fread(fstr, construct_len, 1, construct);
+ if (fread(fstr, construct_len, 1, construct)) {} /* WUR; so pedantic */
replace_endl(fstr, construct_len);
/* construct a hashtable from it */
printf("%f seconds (%lu microseconds)\n", micros / 1000000.0, micros);
/* now search using search file */
- fread(fstr, search_len, 1, search);
+ if (fread(fstr, search_len, 1, search)) {} /* WUR; so pedantic */
replace_endl(fstr, search_len);
/* timings start */