From 73caefebcad990b51045b4765f085ab0dc688524 Mon Sep 17 00:00:00 2001 From: Gerhard Jaeger Date: Fri, 10 Oct 2003 06:57:36 +0000 Subject: [PATCH] Fixed some compilation errors on Darwin and OS/2. --- ChangeLog | 6 +++++- sanei/sanei_thread.c | 9 +++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 5d9ec06f7..c22e60409 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2003-10-10 Gerhard Jaeger + + * sanei/sanei_thread.c: Fixed some compilation errors on Darwin and OS/2 + 2003-10-09 Peter Kirchgessner * backend/hp.c backend/hp-option.c backend/hp-scl.c: @@ -10,7 +14,7 @@ * backend/umax_pp.c backend/umax_pp_low.h backend/umax_pp.h backend/umax_pp_mid.c backend/umax_pp_low.c backend/umax_pp_mid.h - backend/umax_pp.conf: added automatic parallel port detection, + backend/umax_pp.conf: added automatic parallel port detection, and special keyword in configuration file to use it. 2003-10-08 Gerhard Jaeger diff --git a/sanei/sanei_thread.c b/sanei/sanei_thread.c index 63db47a63..2418c6188 100644 --- a/sanei/sanei_thread.c +++ b/sanei/sanei_thread.c @@ -90,7 +90,7 @@ sanei_thread_init( void ) * */ int -sanei_thread_begin( void (*func)(void *args), void* args ) +sanei_thread_begin( int (*func)(void *args), void* args ) { return _beginthread( func, NULL, 1024*1024, args ); } @@ -104,7 +104,7 @@ sanei_thread_kill( int pid ) int sanei_thread_waitpid( int pid, int *status ) { - if (status + if (status) *status = 0; return pid; /* DosWaitThread( (TID*) &pid, DCWW_WAIT);*/ } @@ -132,6 +132,11 @@ sanei_thread_get_status( int pid ) #ifdef USE_PTHREAD +/* seems to be undefined in MacOS X */ +#ifndef PTHREAD_CANCELED +# define PTHREAD_CANCELED ((void *) -1) +#endif + typedef struct { int (*func)( void* );