Whenever system called utimes, the error message returned was EINVAL,
because the member variable of struct timeval was not initialized,
so initialize it.

Signed-off-by: WangYong <[email protected]>

diff -Nurp ltp-full-20090630/testcases/kernel/syscalls/utimes/utimes01.c
ltp-full-20090630.new/testcases/kernel/syscalls/utimes/utimes01.c
--- ltp.orig/testcases/kernel/syscalls/utimes/utimes01.c 2009-07-01
17:20:12.000000000 +0800
+++ ltp/testcases/kernel/syscalls/utimes/utimes01.c  2009-07-08
17:20:38.000000000 +0800
@@ -248,6 +248,7 @@ static int do_test(struct test_case *tc)
          /*
           * Execute system call
           */
+        memset(tv, 0, 2 * sizeof(struct timeval));
          tv[0].tv_sec = tc->a_sec;
          tv[1].tv_sec = tc->m_sec;
          TEST(len = strlen(fpath));



------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize  
details at: http://p.sf.net/sfu/Challenge
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

Reply via email to