I found that some of the testcases in kernel/syscalls redefine 'errno' as 'int':

  int errno;

'errno' is normally in errno.h as a #define to a function returning a pointer, i.e.,

  extern int *__errno_location (void)  . . .


Attached is a patch to remove the redefinition from the following files:

  testcases/kernel/syscalls/mallopt/mallopt01.c
  testcases/kernel/syscalls/memcmp/memcmp01.c
  testcases/kernel/syscalls/memcpy/memcpy01.c
  testcases/kernel/syscalls/memset/memset01.c
  testcases/kernel/syscalls/syscall/syscall01.c
  testcases/kernel/syscalls/string/string01.c


Signed-off-by: d.marlin <[email protected]>

--- testcases/kernel/syscalls/mallopt/mallopt01.c.orig	2010-07-03 13:29:23.000000000 -0500
+++ testcases/kernel/syscalls/mallopt/mallopt01.c	2010-08-13 10:28:12.318231274 -0500
@@ -51,7 +51,6 @@
 
 char *TCID = "mallopt01";
 int block_number;
-int errno;
 FILE *temp;
 int TST_TOTAL = 1;
 extern int Tst_COUNT;		/* Test Case counter for tst_routines */
--- testcases/kernel/syscalls/memcmp/memcmp01.c.orig	2010-07-20 17:40:58.107370000 -0500
+++ testcases/kernel/syscalls/memcmp/memcmp01.c	2010-07-20 16:51:07.468426000 -0500
@@ -57,7 +57,6 @@
 /*****	LTP Port	*****/
 int local_flag = PASSED;
 int block_number;
-int errno;
 FILE *temp;
 int TST_TOTAL = 2;
 int anyfail();
--- testcases/kernel/syscalls/memcpy/memcpy01.c.orig	2010-07-20 17:40:58.116371000 -0500
+++ testcases/kernel/syscalls/memcpy/memcpy01.c	2010-07-20 16:51:10.206237000 -0500
@@ -61,7 +61,6 @@
 /*****	LTP Port	*****/
 int local_flag = PASSED;
 int block_number;
-int errno;
 FILE *temp;
 int TST_TOTAL = 1;
 /*****	**	**	*****/
--- testcases/kernel/syscalls/memset/memset01.c.orig	2010-07-20 17:40:58.127370000 -0500
+++ testcases/kernel/syscalls/memset/memset01.c	2010-07-20 16:51:13.531048000 -0500
@@ -57,7 +57,6 @@
 /*****	LTP Port	*****/
 int local_flag = PASSED;
 int block_number;
-int errno;
 int TST_TOTAL = 1;
 
 extern int Tst_count;
--- testcases/kernel/syscalls/syscall/syscall01.c.orig	2010-07-20 17:40:58.136370000 -0500
+++ testcases/kernel/syscalls/syscall/syscall01.c	2010-07-20 16:51:18.080796000 -0500
@@ -52,7 +52,6 @@
 char *TCID = "syscall01";
 int local_flag = PASSED;
 int block_number;
-int errno;
 FILE *temp;
 int TST_TOTAL = 1;
 extern int Tst_count;
@@ -63,7 +62,6 @@
 #define ITER		500
 
 int t_flag;
-int errno;
 
 /*****	LTP Port	*****/
 void setup();
--- testcases/kernel/syscalls/string/string01.c.orig	2010-08-09 15:56:12.859181562 -0500
+++ testcases/kernel/syscalls/string/string01.c	2010-08-09 15:58:32.475110931 -0500
@@ -52,7 +52,6 @@
 
 int local_flag = PASSED;
 int block_number;
-int errno;
 FILE *temp;
 int TST_TOTAL = 1;
 extern int Tst_count;
------------------------------------------------------------------------------
This SF.net email is sponsored by 

Make an app they can't live without
Enter the BlackBerry Developer Challenge
http://p.sf.net/sfu/RIM-dev2dev 
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

Reply via email to