From a67e6486dfa7ca60b5cda162effa2ab9a65d54d3 Mon Sep 17 00:00:00 2001 From: Alexandre Julliard Date: Fri, 18 May 2001 23:21:22 +0000 Subject: [PATCH] Removed THREAD_IsWin16. --- include/thread.h | 1 - loader/task.c | 8 ++++---- scheduler/thread.c | 8 -------- 3 files changed, 4 insertions(+), 13 deletions(-) diff --git a/include/thread.h b/include/thread.h index 6f46457aab7..03c4ba733ce 100644 --- a/include/thread.h +++ b/include/thread.h @@ -127,7 +127,6 @@ typedef struct _TEB /* scheduler/thread.c */ extern void THREAD_Init(void); extern TEB *THREAD_InitStack( TEB *teb, DWORD stack_size ); -extern BOOL THREAD_IsWin16( TEB *thdb ); extern TEB *THREAD_IdToTEB( DWORD id ); /* scheduler/sysdeps.c */ diff --git a/loader/task.c b/loader/task.c index 4077211e836..49fe403479c 100644 --- a/loader/task.c +++ b/loader/task.c @@ -579,7 +579,7 @@ BOOL16 WINAPI WaitEvent16( HTASK16 hTask ) if (!hTask) hTask = GetCurrentTask(); pTask = TASK_GetPtr( hTask ); - if ( !THREAD_IsWin16( NtCurrentTeb() ) ) + if (pTask->flags & TDBF_WIN32) { FIXME("called for Win32 thread (%04x)!\n", NtCurrentTeb()->teb_sel); return TRUE; @@ -618,7 +618,7 @@ void WINAPI PostEvent16( HTASK16 hTask ) if (!hTask) hTask = GetCurrentTask(); if (!(pTask = TASK_GetPtr( hTask ))) return; - if ( !THREAD_IsWin16( pTask->teb ) ) + if (pTask->flags & TDBF_WIN32) { FIXME("called for Win32 thread (%04x)!\n", pTask->teb->teb_sel ); return; @@ -700,7 +700,7 @@ void WINAPI DirectedYield16( HTASK16 hTask ) { TDB *pCurTask = TASK_GetCurrent(); - if ( !THREAD_IsWin16( NtCurrentTeb() ) ) + if (pCurTask->flags & TDBF_WIN32) { FIXME("called for Win32 thread (%04x)!\n", NtCurrentTeb()->teb_sel); return; @@ -1043,7 +1043,7 @@ HANDLE WINAPI GetFastQueue16( void ) return 0; } } - Callout.InitThreadInput16( 0, THREAD_IsWin16(teb)? 4 : 5 ); + Callout.InitThreadInput16( 0, (teb->tibflags & TEBF_WIN32) ? 5 : 4 ); if (!teb->queue) FIXME("(): should initialize thread-local queue, expect failure!\n" ); diff --git a/scheduler/thread.c b/scheduler/thread.c index 9bc1f64f616..cf84b5031d8 100644 --- a/scheduler/thread.c +++ b/scheduler/thread.c @@ -37,14 +37,6 @@ static TEB initial_teb; extern struct _PDB current_process; -/*********************************************************************** - * THREAD_IsWin16 - */ -BOOL THREAD_IsWin16( TEB *teb ) -{ - return !teb || !(teb->tibflags & TEBF_WIN32); -} - /*********************************************************************** * THREAD_IdToTEB *