[sane-devel] Thread code review and testers
chris at cnpbagwell.com
Mon Nov 7 02:26:50 UTC 2011
I'm looking for a reviewer of attached patch and I'm also hoping
someone has a scanner who's driver uses threads can test this patch to
verify no regressions occurred (be sure and use --enable-pthread on
Current code assumes/requires that SANE_Pid is represented as an
integer on all platforms because we do "pid == -1" checks everywhere.
Pthreads says that it can not be assumed pthread_t is an integer and
on windows platform it in fact is not an integer. Attached is my
solution to abstract out checks for valid PID's so that it will work
with windows and any other pthread implementation that is similar.
For each backend that gets ported to mingw and uses threads, it will
need to switch to use sanei_thread_is_invalid(pid) instead of (pid ==
-1). That was not done as a part of this test patch.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 4374 bytes
Desc: not available
More information about the sane-devel