kernel32/tests: Use better types than long.

This commit is contained in:
Michael Stefaniuc 2009-10-06 00:53:32 +02:00 committed by Alexandre Julliard
parent 29fc53b632
commit 73d38b047b

View File

@ -77,9 +77,9 @@ static void test__hread( void )
{ {
HFILE filehandle; HFILE filehandle;
char buffer[10000]; char buffer[10000];
long bytes_read; LONG bytes_read;
long bytes_wanted; LONG bytes_wanted;
long i; LONG i;
BOOL ret; BOOL ret;
SetFileAttributesA(filename,FILE_ATTRIBUTE_NORMAL); /* be sure to remove stale files */ SetFileAttributesA(filename,FILE_ATTRIBUTE_NORMAL); /* be sure to remove stale files */
@ -124,10 +124,10 @@ static void test__hwrite( void )
{ {
HFILE filehandle; HFILE filehandle;
char buffer[10000]; char buffer[10000];
long bytes_read; LONG bytes_read;
long bytes_written; LONG bytes_written;
long blocks; ULONG blocks;
long i; LONG i;
char *contents; char *contents;
HLOCAL memory_object; HLOCAL memory_object;
char checksum[1]; char checksum[1];
@ -159,7 +159,7 @@ static void test__hwrite( void )
srand( (unsigned)time( NULL ) ); srand( (unsigned)time( NULL ) );
for (blocks = 0; blocks < 100; blocks++) for (blocks = 0; blocks < 100; blocks++)
{ {
for (i = 0; i < (long)sizeof( buffer ); i++) for (i = 0; i < (LONG)sizeof( buffer ); i++)
{ {
buffer[i] = rand( ); buffer[i] = rand( );
checksum[0] = checksum[0] + buffer[i]; checksum[0] = checksum[0] + buffer[i];
@ -355,7 +355,7 @@ static void test__llseek( void )
INT i; INT i;
HFILE filehandle; HFILE filehandle;
char buffer[1]; char buffer[1];
long bytes_read; LONG bytes_read;
BOOL ret; BOOL ret;
filehandle = _lcreat( filename, 0 ); filehandle = _lcreat( filename, 0 );
@ -432,7 +432,7 @@ static void test__lread( void )
{ {
HFILE filehandle; HFILE filehandle;
char buffer[10000]; char buffer[10000];
long bytes_read; UINT bytes_read;
UINT bytes_wanted; UINT bytes_wanted;
UINT i; UINT i;
BOOL ret; BOOL ret;
@ -477,10 +477,10 @@ static void test__lwrite( void )
{ {
HFILE filehandle; HFILE filehandle;
char buffer[10000]; char buffer[10000];
long bytes_read; UINT bytes_read;
long bytes_written; UINT bytes_written;
long blocks; UINT blocks;
long i; INT i;
char *contents; char *contents;
HLOCAL memory_object; HLOCAL memory_object;
char checksum[1]; char checksum[1];
@ -512,7 +512,7 @@ static void test__lwrite( void )
srand( (unsigned)time( NULL ) ); srand( (unsigned)time( NULL ) );
for (blocks = 0; blocks < 100; blocks++) for (blocks = 0; blocks < 100; blocks++)
{ {
for (i = 0; i < (long)sizeof( buffer ); i++) for (i = 0; i < (INT)sizeof( buffer ); i++)
{ {
buffer[i] = rand( ); buffer[i] = rand( );
checksum[0] = checksum[0] + buffer[i]; checksum[0] = checksum[0] + buffer[i];