Use test-driver in sysdeps/unix/sysv/linux/tst-clone2.c

Message ID 20170607114139.GA65837@aloka.lostca.se
State New, archived
Headers

Commit Message

Arjun Shankar June 7, 2017, 11:41 a.m. UTC
  This test already uses macros defined in support/check.h. Having it use this
and test-skeleton.c at the same complicates backports somewhat.

ChangeLog:

2017-06-07  Arjun Shankar  <arjun.is@lostca.se>

	* sysdeps/unix/sysv/linux/tst-clone2.c: Do not
	include test-skeleton.c.
	Include support/check.h and support/test-driver.c.
---
 sysdeps/unix/sysv/linux/tst-clone2.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)
  

Comments

Florian Weimer June 7, 2017, 11:53 a.m. UTC | #1
On 06/07/2017 01:41 PM, Arjun Shankar wrote:
> This test already uses macros defined in support/check.h. Having it use this
> and test-skeleton.c at the same complicates backports somewhat.
> 
> ChangeLog:
> 
> 2017-06-07  Arjun Shankar  <arjun.is@lostca.se>
> 
> 	* sysdeps/unix/sysv/linux/tst-clone2.c: Do not
> 	include test-skeleton.c.
> 	Include support/check.h and support/test-driver.c.

Looks good to me.  Please commit.

Thanks,
Florian
  

Patch

diff --git a/sysdeps/unix/sysv/linux/tst-clone2.c b/sysdeps/unix/sysv/linux/tst-clone2.c
index 4e9379b..f53efd5 100644
--- a/sysdeps/unix/sysv/linux/tst-clone2.c
+++ b/sysdeps/unix/sysv/linux/tst-clone2.c
@@ -32,10 +32,7 @@ 
 
 #include <stackinfo.h>  /* For _STACK_GROWS_{UP,DOWN}.  */
 
-static int do_test (void);
-
-#define TEST_FUNCTION do_test ()
-#include <test-skeleton.c>
+#include <support/check.h>
 
 static int sig;
 static int pipefd[2];
@@ -145,3 +142,5 @@  do_test (void)
 
   return ret;
 }
+
+#include <support/test-driver.c>