Implemented PsCreateSystemThread in ntoskrnl.exe
Robert Shearman
rob at codeweavers.com
Thu Sep 20 15:52:35 CDT 2007
Juan Lang wrote:
> Hi Carroll,
>
> + if (ProcessHandle!=0)
> + localThreadHandle =
> CreateRemoteThread(ProcessHandle,0,0,StartRoutine,StartContext,0,&ThreadId);
> + else localThreadHandle =
> CreateThread(0,0,StartRoutine,StartContext,0,&ThreadId);
> +
> + if (localThreadHandle==0) return STATUS_SEVERITY_ERROR;
>
> You should use NtCreateThread rather than CreateThread. It also
> returns a proper status, so you don't have to guess like you do here.
>
Actually, NtCreateThread is too low-level and so isn't implemented in
Wine. RtlCreateUserThread might be better to use though.
--
Rob Shearman
More information about the wine-devel
mailing list