msvcrt: Sign-compare warnings fix.

This commit is contained in:
Andrew Talbot 2008-10-21 21:44:27 +01:00 committed by Alexandre Julliard
parent 86a0b2915a
commit 4c3d27dfee
5 changed files with 11 additions and 8 deletions

View File

@ -121,7 +121,7 @@ int CDECL _getch(void)
do {
if (ReadConsoleInputA(MSVCRT_console_in, &ir, 1, &count))
{
int i;
unsigned int i;
/* Only interested in ASCII chars */
if (ir.EventType == KEY_EVENT &&
ir.Event.KeyEvent.bKeyDown)

View File

@ -478,7 +478,8 @@ static LONG WINAPI msvcrt_exception_filter(struct _EXCEPTION_POINTERS *except)
{
if (handler != MSVCRT_SIG_IGN)
{
int i, float_signal = _FPE_INVALID;
unsigned int i;
int float_signal = _FPE_INVALID;
sighandlers[MSVCRT_SIGFPE] = MSVCRT_SIG_DFL;
for (i = 0; i < sizeof(float_exception_map) /

View File

@ -1686,7 +1686,7 @@ static int read_i(int fd, void *buf, unsigned int count)
{
if (MSVCRT_fdesc[fd].wxflag & WX_TEXT)
{
int i;
DWORD i;
/* in text mode, a ctrl-z signals EOF */
for (i=0; i<num_read; i++)
{
@ -2281,7 +2281,8 @@ MSVCRT_wint_t CDECL MSVCRT_fgetwc(MSVCRT_FILE* file)
if (!(MSVCRT_fdesc[file->_file].wxflag & WX_TEXT))
{
MSVCRT_wchar_t wc;
int i,j;
unsigned int i;
int j;
char *chp, *wcp;
wcp = (char *)&wc;
for(i=0; i<sizeof(wc); i++)
@ -2324,7 +2325,8 @@ MSVCRT_wint_t CDECL MSVCRT_fgetwc(MSVCRT_FILE* file)
int CDECL MSVCRT__getw(MSVCRT_FILE* file)
{
char *ch;
int i, j, k;
int i, k;
unsigned int j;
ch = (char *)&i;
for (j=0; j<sizeof(int); j++) {
k = MSVCRT_fgetc(file);

View File

@ -348,7 +348,7 @@ static char* get_args(struct parsed_symbol* sym, struct array* pmt_ref, BOOL z_t
struct datatype_t ct;
struct array arg_collect;
char* args_str = NULL;
int i;
unsigned int i;
str_array_init(&arg_collect);

View File

@ -1034,7 +1034,7 @@ INT CDECL MSVCRT_iswxdigit( MSVCRT_wchar_t wc )
*/
INT CDECL MSVCRT_wcscpy_s( MSVCRT_wchar_t* wcDest, MSVCRT_size_t numElement, const MSVCRT_wchar_t *wcSrc)
{
INT size = 0;
MSVCRT_size_t size = 0;
if(!wcDest || !numElement)
return MSVCRT_EINVAL;
@ -1067,7 +1067,7 @@ INT CDECL MSVCRT_wcscpy_s( MSVCRT_wchar_t* wcDest, MSVCRT_size_t numElement, con
INT CDECL MSVCRT_wcsncpy_s( MSVCRT_wchar_t* wcDest, MSVCRT_size_t numElement, const MSVCRT_wchar_t *wcSrc,
MSVCRT_size_t count )
{
INT size = 0;
MSVCRT_size_t size = 0;
if (!wcDest || !numElement)
return MSVCRT_EINVAL;