Hi, please review the attached patch
--
markos
>From d83355aa7d9c197a60a1f1c5e495fa049a2f1861 Mon Sep 17 00:00:00 2001
From: Markos Chandras <[email protected]>
Date: Thu, 22 Dec 2011 15:25:03 +0000
Subject: [PATCH 21/21] network/nfsv4/acl: Second argument is execl should be a
null-terminated array
>From exec manpage:
"The const char *arg and subsequent ellipses in the execl(), execlp(), and
execle() functions can be thought of as arg0, arg1, ..., argn. Together
they describe a list of one or more pointers to null-terminated strings
that represent the argument list available to the executed program". This
change will silence gcc warnings.
Signed-off-by: Markos Chandras <[email protected]>
---
testcases/network/nfsv4/acl/acl1.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/testcases/network/nfsv4/acl/acl1.c
b/testcases/network/nfsv4/acl/acl1.c
index 18a92a0..5040eee 100644
--- a/testcases/network/nfsv4/acl/acl1.c
+++ b/testcases/network/nfsv4/acl/acl1.c
@@ -57,12 +57,13 @@ int do_file_op(char* filename) {
result = 0;
FILE *fptr;
char str[256] = "./";
+ const char execl_args[] = {'\0'};
fptr = malloc(sizeof(FILE));
uid = geteuid();
strcat(str, filename);
- exe = execl(str,NULL,NULL);
+ exe = execl(str,execl_args,NULL);
if (exe == -1 && errno!=EACCES)
result = result + OP_EXEC;
--
1.7.1
------------------------------------------------------------------------------
Write once. Port to many.
Get the SDK and tools to simplify cross-platform app development. Create
new or port existing apps to sell to consumers worldwide. Explore the
Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join
http://p.sf.net/sfu/intel-appdev
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list