fs/stream: ret variable is has an integer type not size_t
PATCH 15/21 fs/stream: ret variable is has an integer type not size_t
Hi, please review the attached patch
Signature · 1 line
markos
From fd8d55e8194f7e56d35c4a291e5a64aa09f24237 Mon Sep 17 00:00:00 2001
From: Markos Chandras <[email protected]>
Date: Thu, 22 Dec 2011 14:53:01 +0000
Subject: [PATCH 15/21] fs/stream: ret variable is has an integer type not size_t
--- testcases/kernel/fs/stream/stream04.c | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-)
testcases/kernel/fs/stream/stream04.c +3 -3
@@ -88,7 +88,7 @@ int main(int ac, char *av[]) }if ((size_t )ret !=strlen (junk)) { -tst_resm (TFAIL ,"strlen(junk) = %zi != return value from fwrite = %zi" ,strlen (junk), ret); +tst_resm (TFAIL ,"strlen(junk) = %zi != return value from fwrite = %d" ,strlen (junk), ret); local_flag =FAILED ; }
@@ -109,7 +109,7 @@ int main(int ac, char *av[])tst_exit (); }if ((size_t )ret !=strlen (junk)) { -tst_resm (TFAIL ,"strlen(junk) = %zi != return value from fread = %zi" ,strlen (junk), ret); +tst_resm (TFAIL ,"strlen(junk) = %zi != return value from fread = %d" ,strlen (junk), ret); local_flag =FAILED ; }fclose (stream);
@@ -123,4 +123,4 @@ int main(int ac, char *av[]) }/* end for */ tst_rmdir ();tst_exit (); -} +}
Signature · 1 line
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
Quoted 1 line · On Tuesday 03 January 2012 08:20:56 Markos Chandras wrote:
Hi, please review the attached patch
seems to me the proper fix in this file is to make "ret" into a "size_t". it holds the return values of fwrite/fread which both return size_t, not int. -mike
------------------------------------------------------------------------------
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