This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH 1/2] Fix GCC split-stack variadic argument tests
- From: Adhemerval Zanella <adhemerval dot zanella at linaro dot org>
- To: gcc-patches at gcc dot gnu dot org
- Cc: kyrylo dot tkachov at foss dot arm dot com, marcus dot shawcroft at arm dot com, Richard dot Earnshaw at arm dot com, james dot greenhalgh at arm dot com
- Date: Mon, 17 Oct 2016 17:12:21 -0200
- Subject: [PATCH 1/2] Fix GCC split-stack variadic argument tests
- Authentication-results: sourceware.org; auth=none
This test adds the expect va_end after va_start on split-stack tests.
gcc/ChangeLog:
* gcc/testsuite/gcc.dg/split-3.c (down): Call va_end after va_start.
* gcc/testsuite/gcc.dg/split-6.c (down): Likewise.
---
gcc/ChangeLog | 5 +++++
gcc/testsuite/gcc.dg/split-3.c | 1 +
gcc/testsuite/gcc.dg/split-6.c | 1 +
3 files changed, 7 insertions(+)
diff --git a/gcc/testsuite/gcc.dg/split-3.c b/gcc/testsuite/gcc.dg/split-3.c
index 64bbb8c..5ba7616 100644
--- a/gcc/testsuite/gcc.dg/split-3.c
+++ b/gcc/testsuite/gcc.dg/split-3.c
@@ -40,6 +40,7 @@ down (int i, ...)
|| va_arg (ap, int) != 9
|| va_arg (ap, int) != 10)
abort ();
+ va_end (ap);
if (i > 0)
{
diff --git a/gcc/testsuite/gcc.dg/split-6.c b/gcc/testsuite/gcc.dg/split-6.c
index b32cf8d..b3016ba 100644
--- a/gcc/testsuite/gcc.dg/split-6.c
+++ b/gcc/testsuite/gcc.dg/split-6.c
@@ -37,6 +37,7 @@ down (int i, ...)
|| va_arg (ap, int) != 9
|| va_arg (ap, int) != 10)
abort ();
+ va_end (ap);
if (i > 0)
{
--
2.7.4