Alexandre Julliard : libwine: Added entry for sigprocmask in the pthread functions table.

Alexandre Julliard julliard at wine.codeweavers.com
Fri Jun 23 06:43:56 CDT 2006


Module: wine
Branch: refs/heads/master
Commit: e040e6c4f8dd20b7b52d843aefe1d6a6c5c0047d
URL:    http://source.winehq.org/git/?p=wine.git;a=commit;h=e040e6c4f8dd20b7b52d843aefe1d6a6c5c0047d

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Fri Jun 23 12:27:45 2006 +0200

libwine: Added entry for sigprocmask in the pthread functions table.

---

 dlls/ntdll/server.c    |    8 ++++----
 include/wine/pthread.h |    3 +++
 loader/kthread.c       |    3 ++-
 loader/pthread.c       |    3 ++-
 4 files changed, 11 insertions(+), 6 deletions(-)

diff --git a/dlls/ntdll/server.c b/dlls/ntdll/server.c
index cffc407..b10a391 100644
--- a/dlls/ntdll/server.c
+++ b/dlls/ntdll/server.c
@@ -159,7 +159,7 @@ void server_exit_thread( int status )
     NtFreeVirtualMemory( GetCurrentProcess(), &info.teb_base, &size, MEM_RELEASE | MEM_SYSTEM );
     info.teb_size = size;
 
-    sigprocmask( SIG_BLOCK, &block_set, NULL );
+    pthread_functions.sigprocmask( SIG_BLOCK, &block_set, NULL );
     close( ntdll_get_thread_data()->wait_fd[0] );
     close( ntdll_get_thread_data()->wait_fd[1] );
     close( ntdll_get_thread_data()->reply_fd );
@@ -173,7 +173,7 @@ void server_exit_thread( int status )
  */
 void server_abort_thread( int status )
 {
-    sigprocmask( SIG_BLOCK, &block_set, NULL );
+    pthread_functions.sigprocmask( SIG_BLOCK, &block_set, NULL );
     close( ntdll_get_thread_data()->wait_fd[0] );
     close( ntdll_get_thread_data()->wait_fd[1] );
     close( ntdll_get_thread_data()->reply_fd );
@@ -312,10 +312,10 @@ unsigned int wine_server_call( void *req
     struct __server_request_info * const req = req_ptr;
     sigset_t old_set;
 
-    sigprocmask( SIG_BLOCK, &block_set, &old_set );
+    pthread_functions.sigprocmask( SIG_BLOCK, &block_set, &old_set );
     send_request( req );
     wait_reply( req );
-    sigprocmask( SIG_SETMASK, &old_set, NULL );
+    pthread_functions.sigprocmask( SIG_SETMASK, &old_set, NULL );
     return req->u.reply.reply_header.error;
 }
 
diff --git a/include/wine/pthread.h b/include/wine/pthread.h
index 3d62d9d..69a1562 100644
--- a/include/wine/pthread.h
+++ b/include/wine/pthread.h
@@ -23,6 +23,8 @@ #define __WINE_WINE_PTHREAD_H
 
 struct wine_pthread_callbacks;
 
+#include <signal.h>
+
 #ifdef HAVE_PTHREAD_H
 
 #define _GNU_SOURCE
@@ -99,6 +101,7 @@ #else
     void   (*exit_thread)( struct wine_pthread_thread_info *info );
     void   (*abort_thread)( long status );
 #endif
+    int    (*sigprocmask)( int how, const sigset_t *newset, sigset_t *oldset );
 };
 
 extern void wine_pthread_get_functions( struct wine_pthread_functions *functions, size_t size );
diff --git a/loader/kthread.c b/loader/kthread.c
index 4320e80..a012aad 100644
--- a/loader/kthread.c
+++ b/loader/kthread.c
@@ -397,7 +397,8 @@ const struct wine_pthread_functions pthr
     init_current_teb,
     get_current_teb,
     exit_thread,
-    abort_thread
+    abort_thread,
+    sigprocmask
 };
 
 
diff --git a/loader/pthread.c b/loader/pthread.c
index 5c6632d..b7487a0 100644
--- a/loader/pthread.c
+++ b/loader/pthread.c
@@ -184,7 +184,8 @@ const struct wine_pthread_functions pthr
     init_current_teb,
     get_current_teb,
     exit_thread,
-    abort_thread
+    abort_thread,
+    pthread_sigmask
 };
 
 #endif  /* HAVE_PTHREAD_H */




More information about the wine-cvs mailing list