summaryrefslogtreecommitdiff
path: root/debian/patches
diff options
context:
space:
mode:
authorYves-Alexis Perez <corsac@debian.org>2014-04-02 21:20:31 +0200
committerYves-Alexis Perez <corsac@debian.org>2014-04-02 21:27:17 +0200
commit53b649bca6d8d323d2b64f4e2357497acb978910 (patch)
tree2b54fe1795f107e17d90650fa7f07404995302b3 /debian/patches
parent30fdd655491ddae3b8a998ad6e60ae84e87fa973 (diff)
downloadvyos-strongswan-53b649bca6d8d323d2b64f4e2357497acb978910.tar.gz
vyos-strongswan-53b649bca6d8d323d2b64f4e2357497acb978910.zip
Add patch to fix testsuite failure on armel
Diffstat (limited to 'debian/patches')
-rw-r--r--debian/patches/03_unit-tests-Fix-chunk-clear-armel.patch19
-rw-r--r--debian/patches/series1
2 files changed, 20 insertions, 0 deletions
diff --git a/debian/patches/03_unit-tests-Fix-chunk-clear-armel.patch b/debian/patches/03_unit-tests-Fix-chunk-clear-armel.patch
new file mode 100644
index 000000000..eb92fac71
--- /dev/null
+++ b/debian/patches/03_unit-tests-Fix-chunk-clear-armel.patch
@@ -0,0 +1,19 @@
+--- a/src/libstrongswan/tests/suites/test_chunk.c
++++ b/src/libstrongswan/tests/suites/test_chunk.c
+@@ -117,10 +117,13 @@ START_TEST(test_chunk_clear)
+ }
+ chunk_clear(&chunk);
+ /* check memory area of freed chunk. We can't use ck_assert() for this
+- * test directly, as it might allocate data at the freed area. */
+- for (i = 0; i < 64; i++)
++ * test directly, as it might allocate data at the freed area. comparing
++ * two bytes at once reduces the chances of conflicts if memory got
++ * overwritten already */
++ for (i = 0; i < 64; i += 2)
+ {
+- if (ptr[i] != 0 && ptr[i] == i)
++ if (ptr[i] != 0 && ptr[i] == i &&
++ ptr[i+1] != 0 && ptr[i+1] == i+1)
+ {
+ cleared = FALSE;
+ break;
diff --git a/debian/patches/series b/debian/patches/series
index 06fa1b5d0..d31e3c5c2 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,2 +1,3 @@
01_fix-manpages.patch
02_unit-tests-Fix-filtered-enumerator-tests-on-64-bit-b.patch
+03_unit-tests-Fix-chunk-clear-armel.patch