aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'patches/libaio/0.3.110/libaio-0.3.109-testcase-8.patch')
-rw-r--r--patches/libaio/0.3.110/libaio-0.3.109-testcase-8.patch19
1 files changed, 19 insertions, 0 deletions
diff --git a/patches/libaio/0.3.110/libaio-0.3.109-testcase-8.patch b/patches/libaio/0.3.110/libaio-0.3.109-testcase-8.patch
new file mode 100644
index 0000000..de66f21
--- /dev/null
+++ b/patches/libaio/0.3.110/libaio-0.3.109-testcase-8.patch
@@ -0,0 +1,19 @@
+Do not ignore return value of ftruncate(): testcases are compiled with -Werror,
+and ftruncate is declared with attribute warn_unused_result.
+--- harness/cases/8.t.orig 2012-03-09 16:40:04.074168070 +0100
++++ harness/cases/8.t 2012-03-09 16:40:57.777278646 +0100
+@@ -9,12 +9,13 @@
+ {
+ long long min = 0, max = 9223372036854775807LL;
+ char c = 0;
++ int ret;
+
+ while (max - min > 1) {
+ if (pwrite64(fd, &c, 1, (min + max) / 2) == -1)
+ max = (min + max) / 2;
+ else {
+- ftruncate(fd, 0);
++ ret = ftruncate(fd, 0); assert(ret == 0);
+ min = (min + max) / 2;
+ }
+ }