Commit c9a10b32 authored by Michael Stefaniuc's avatar Michael Stefaniuc Committed by Alexandre Julliard

kernel32: Do not cast zero.

parent efeab9d2
...@@ -1750,7 +1750,7 @@ FARPROC16 WINAPI GetProcAddress16( HMODULE16 hModule, LPCSTR name ) ...@@ -1750,7 +1750,7 @@ FARPROC16 WINAPI GetProcAddress16( HMODULE16 hModule, LPCSTR name )
ordinal = LOWORD(name); ordinal = LOWORD(name);
TRACE("%04x %04x\n", hModule, ordinal ); TRACE("%04x %04x\n", hModule, ordinal );
} }
if (!ordinal) return (FARPROC16)0; if (!ordinal) return NULL;
ret = NE_GetEntryPoint( hModule, ordinal ); ret = NE_GetEntryPoint( hModule, ordinal );
......
...@@ -205,7 +205,7 @@ static SEGPTR TASK_AllocThunk(void) ...@@ -205,7 +205,7 @@ static SEGPTR TASK_AllocThunk(void)
{ {
sel = GLOBAL_Alloc( GMEM_FIXED, sizeof(THUNKS) + (MIN_THUNKS-1)*8, sel = GLOBAL_Alloc( GMEM_FIXED, sizeof(THUNKS) + (MIN_THUNKS-1)*8,
pTask->hPDB, WINE_LDT_FLAGS_CODE ); pTask->hPDB, WINE_LDT_FLAGS_CODE );
if (!sel) return (SEGPTR)0; if (!sel) return 0;
TASK_CreateThunks( sel, 0, MIN_THUNKS ); TASK_CreateThunks( sel, 0, MIN_THUNKS );
pThunk->next = sel; pThunk->next = sel;
} }
...@@ -860,7 +860,7 @@ FARPROC16 WINAPI MakeProcInstance16( FARPROC16 func, HANDLE16 hInstance ) ...@@ -860,7 +860,7 @@ FARPROC16 WINAPI MakeProcInstance16( FARPROC16 func, HANDLE16 hInstance )
if (!HIWORD(func)) { if (!HIWORD(func)) {
/* Win95 actually protects via SEH, but this is better for debugging */ /* Win95 actually protects via SEH, but this is better for debugging */
WARN("Ouch ! Called with invalid func %p !\n", func); WARN("Ouch ! Called with invalid func %p !\n", func);
return (FARPROC16)0; return NULL;
} }
if ( (GlobalHandleToSel16(CURRENT_DS) != hInstanceSelector) if ( (GlobalHandleToSel16(CURRENT_DS) != hInstanceSelector)
...@@ -884,7 +884,7 @@ FARPROC16 WINAPI MakeProcInstance16( FARPROC16 func, HANDLE16 hInstance ) ...@@ -884,7 +884,7 @@ FARPROC16 WINAPI MakeProcInstance16( FARPROC16 func, HANDLE16 hInstance )
return func; return func;
thunkaddr = TASK_AllocThunk(); thunkaddr = TASK_AllocThunk();
if (!thunkaddr) return (FARPROC16)0; if (!thunkaddr) return NULL;
thunk = MapSL( thunkaddr ); thunk = MapSL( thunkaddr );
lfunc = MapSL( (SEGPTR)func ); lfunc = MapSL( (SEGPTR)func );
...@@ -990,7 +990,7 @@ HANDLE16 WINAPI GetCodeHandle16( FARPROC16 proc ) ...@@ -990,7 +990,7 @@ HANDLE16 WINAPI GetCodeHandle16( FARPROC16 proc )
SEGTABLEENTRY *pSeg; SEGTABLEENTRY *pSeg;
if ( !TASK_GetCodeSegment( proc, NULL, &pSeg, NULL ) ) if ( !TASK_GetCodeSegment( proc, NULL, &pSeg, NULL ) )
return (HANDLE16)0; return 0;
return pSeg->hSeg; return pSeg->hSeg;
} }
......
...@@ -740,8 +740,7 @@ static void test_timer_queue(void) ...@@ -740,8 +740,7 @@ static void test_timer_queue(void)
/* Run once and finish quickly (should be done when we delete it). */ /* Run once and finish quickly (should be done when we delete it). */
t1 = NULL; t1 = NULL;
ret = pCreateTimerQueueTimer(&t1, q, timer_queue_cb5, (PVOID) 0, 0, ret = pCreateTimerQueueTimer(&t1, q, timer_queue_cb5, NULL, 0, 0, 0);
0, 0);
ok(ret, "CreateTimerQueueTimer\n"); ok(ret, "CreateTimerQueueTimer\n");
ok(t1 != NULL, "CreateTimerQueueTimer\n"); ok(t1 != NULL, "CreateTimerQueueTimer\n");
...@@ -754,8 +753,7 @@ static void test_timer_queue(void) ...@@ -754,8 +753,7 @@ static void test_timer_queue(void)
/* Run once and finish quickly (should be done when we delete it). */ /* Run once and finish quickly (should be done when we delete it). */
t3 = NULL; t3 = NULL;
ret = pCreateTimerQueueTimer(&t3, q, timer_queue_cb5, (PVOID) 0, 0, ret = pCreateTimerQueueTimer(&t3, q, timer_queue_cb5, NULL, 0, 0, 0);
0, 0);
ok(ret, "CreateTimerQueueTimer\n"); ok(ret, "CreateTimerQueueTimer\n");
ok(t3 != NULL, "CreateTimerQueueTimer\n"); ok(t3 != NULL, "CreateTimerQueueTimer\n");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment