diff --git a/dlls/winedos/devices.c b/dlls/winedos/devices.c index 368f8e5afa7..49d84d38997 100644 --- a/dlls/winedos/devices.c +++ b/dlls/winedos/devices.c @@ -145,8 +145,8 @@ static REQUEST_HEADER * get_hdr(int id, void**extra) { void **hdr_ptr = strategy_data[id]; if (extra) - *extra = hdr_ptr ? (void*)(hdr_ptr+1) : (void *)NULL; - return hdr_ptr ? *hdr_ptr : (void *)NULL; + *extra = hdr_ptr ? (void*)(hdr_ptr+1) : NULL; + return hdr_ptr ? *hdr_ptr : NULL; } static void WINAPI nul_strategy(CONTEXT86*ctx) diff --git a/dlls/winedos/dosmem.c b/dlls/winedos/dosmem.c index 3f635c7a8a8..9829f1a5b88 100644 --- a/dlls/winedos/dosmem.c +++ b/dlls/winedos/dosmem.c @@ -300,7 +300,7 @@ LPVOID DOSMEM_AllocBlock(UINT size, UINT16* pseg) } /* curr is the found block */ curr->psp = psp; - if( pseg ) *pseg = (((char*)curr) + 16 - (char*)DOSMEM_dosmem) >> 4; + if( pseg ) *pseg = (((char*)curr) + 16 - DOSMEM_dosmem) >> 4; return (LPVOID) ((char*)curr + 16); } } diff --git a/dlls/winedos/int21.c b/dlls/winedos/int21.c index 75aeb1cc4ff..ac9971431e2 100644 --- a/dlls/winedos/int21.c +++ b/dlls/winedos/int21.c @@ -1720,7 +1720,7 @@ static void INT21_RandomBlockReadFromFCB( CONTEXT86 *context ) } else { disk_transfer_area = INT21_GetCurrentDTA(context); records_requested = CX_reg(context); - bytes_requested = (UINT) records_requested * fcb->logical_record_size; + bytes_requested = records_requested * fcb->logical_record_size; bytes_read = _lread((HFILE) handle, disk_transfer_area, bytes_requested); if (bytes_read != bytes_requested) { TRACE("_lread(%d, %p, %d) failed with %d\n", @@ -1811,7 +1811,7 @@ static void INT21_RandomBlockWriteToFCB( CONTEXT86 *context ) } else { disk_transfer_area = INT21_GetCurrentDTA(context); records_requested = CX_reg(context); - bytes_requested = (UINT) records_requested * fcb->logical_record_size; + bytes_requested = records_requested * fcb->logical_record_size; bytes_written = _lwrite((HFILE) handle, (LPCSTR)disk_transfer_area, bytes_requested); if (bytes_written != bytes_requested) { TRACE("_lwrite(%d, %p, %d) failed with %d\n", @@ -5006,7 +5006,7 @@ void WINAPI DOSVM_Int21Handler( CONTEXT86 *context ) } else { - LPVOID address = (void*)((DWORD)context->SegEs << 4); + LPVOID address = (void*)(context->SegEs << 4); UINT blocksize = DOSMEM_ResizeBlock( address, newsize, FALSE ); RESET_CFLAG(context); diff --git a/dlls/winedos/int2f.c b/dlls/winedos/int2f.c index 7bbf5e47b2d..c5b620f4344 100644 --- a/dlls/winedos/int2f.c +++ b/dlls/winedos/int2f.c @@ -556,7 +556,7 @@ static void MSCDEX_Request(BYTE *driver_request, BOOL dorealmode) * the following tests are wrong because lots of functions don't require the * tray to be closed with a CD inside */ - TRACE("CDROM device driver -> command <%d>\n", (unsigned char)driver_request[2]); + TRACE("CDROM device driver -> command <%d>\n", driver_request[2]); MSCDEX_Dump("Beg", driver_request, dorealmode); @@ -846,8 +846,7 @@ static void MSCDEX_Request(BYTE *driver_request, BOOL dorealmode) at = PTR_AT(driver_request, 20, DWORD); - TRACE(" --> SEEK AUDIO mode :<0x%02X>, [%d]\n", - (BYTE)driver_request[13], at); + TRACE(" --> SEEK AUDIO mode :<0x%02X>, [%d]\n", driver_request[13], at); switch (driver_request[13]) { case 1: /* Red book addressing mode = 0:m:s:f */ @@ -881,8 +880,7 @@ static void MSCDEX_Request(BYTE *driver_request, BOOL dorealmode) beg = end = PTR_AT(driver_request, 14, DWORD); end += PTR_AT(driver_request, 18, DWORD); - TRACE(" --> PLAY AUDIO mode :<0x%02X>, [%d-%d]\n", - (BYTE)driver_request[13], beg, end); + TRACE(" --> PLAY AUDIO mode :<0x%02X>, [%d-%d]\n", driver_request[13], beg, end); switch (driver_request[13]) { case 1: diff --git a/dlls/winedos/ioports.c b/dlls/winedos/ioports.c index 13079a77b29..e9f4f7f148b 100644 --- a/dlls/winedos/ioports.c +++ b/dlls/winedos/ioports.c @@ -608,7 +608,7 @@ void WINAPI DOSVM_outport( int port, int size, DWORD value ) break; case 0x61: parport_8255[1] = (BYTE)value; - if ((((BYTE)parport_8255[1] & 3) == 3) && (tmr_8253[2].countmax != 1)) + if (((parport_8255[1] & 3) == 3) && (tmr_8253[2].countmax != 1)) { TRACE("Beep (freq: %d) !\n", 1193180 / tmr_8253[2].countmax); Beep(1193180 / tmr_8253[2].countmax, 20); diff --git a/dlls/winedos/vga.c b/dlls/winedos/vga.c index 2a07f219e47..d236591e1cb 100644 --- a/dlls/winedos/vga.c +++ b/dlls/winedos/vga.c @@ -553,7 +553,7 @@ char VGA_GetColor16(int reg) { if (!lpddraw) return 0; - return (char)vga_16_palette[reg]; + return vga_16_palette[reg]; } /* set all 17 [char wide] colors at once in 16 color mode. */ diff --git a/dlls/winedos/vxd.c b/dlls/winedos/vxd.c index 4a1eabf5bfc..0b3602a6332 100644 --- a/dlls/winedos/vxd.c +++ b/dlls/winedos/vxd.c @@ -875,7 +875,7 @@ void WINAPI VXD_Win32s( CONTEXT86 *context ) * Output: EAX: 1 if OK */ - TRACE("UnMapModule: %x\n", (DWORD)W32S_APP2WINE(context->Edx)); + TRACE("UnMapModule: %x\n", W32S_APP2WINE(context->Edx)); /* As we didn't map anything, there's nothing to unmap ... */