diff options
-rw-r--r-- | Makefile.am | 2 | ||||
-rw-r--r-- | filter.c | 10 | ||||
-rw-r--r-- | filter.h | 2 | ||||
-rw-r--r-- | node.c | 8 | ||||
-rw-r--r-- | node.h | 2 |
5 files changed, 12 insertions, 12 deletions
diff --git a/Makefile.am b/Makefile.am index 672883152..e6fe095df 100644 --- a/Makefile.am +++ b/Makefile.am @@ -48,7 +48,7 @@ filter_LDADD = \ -lnetfs \ -lfshelp \ -liohelp \ - -lthreads \ + -lpthread \ -lports \ -lihash \ -lshouldbeinlibc @@ -84,7 +84,7 @@ error_t LOG_MSG ("netfs_attempt_create_file"); /*Unlock `dir` and say that we can do nothing else here */ - mutex_unlock (&dir->lock); + pthread_mutex_unlock (&dir->lock); return EOPNOTSUPP; } /*netfs_attempt_create_file */ @@ -230,7 +230,7 @@ error_t LOG_MSG ("netfs_attempt_lookup: '%s'", name); /*Unlock the mutexes in `dir` */ - mutex_unlock (&dir->lock); + pthread_mutex_unlock (&dir->lock); return EOPNOTSUPP; } /*netfs_attempt_lookup */ @@ -418,7 +418,7 @@ error_t LOG_MSG ("netfs_attempt_mkfile"); /*Unlock the directory */ - mutex_unlock (&dir->lock); + pthread_mutex_unlock (&dir->lock); /*Operation not supported */ return EOPNOTSUPP; @@ -504,7 +504,7 @@ kern_return_t node_t *np = user->po->np; /*Lock the node */ - mutex_lock (&np->lock); + pthread_mutex_lock (&np->lock); /*Check if the user is the owner of this node */ err = fshelp_isowner (&np->nn_stat, user->user); @@ -525,7 +525,7 @@ kern_return_t *cntltype = MACH_MSG_TYPE_MOVE_SEND; /*Unlock the node */ - mutex_unlock (&np->lock); + pthread_mutex_unlock (&np->lock); /*Return the result of operations */ return err; @@ -28,7 +28,7 @@ /*---------------------------------------------------------------------------*/ #include <stddef.h> #include <stdlib.h> -#include <cthreads.h> +#include <pthread.h> #include <unistd.h> #include <sys/mman.h> #include <sys/types.h> @@ -41,7 +41,7 @@ /*---------------------------------------------------------------------------*/ /*--------Global Variables---------------------------------------------------*/ /*The lock protecting the underlying filesystem*/ -struct mutex ulfs_lock = MUTEX_INITIALIZER; +pthread_mutex_t ulfs_lock = PTHREAD_MUTEX_INITIALIZER; /*---------------------------------------------------------------------------*/ /*---------------------------------------------------------------------------*/ @@ -125,7 +125,7 @@ error_t node_init_root (mach_port_t underlying, /*the port to the error_t err = 0; /*Acquire a lock for operations on the underlying filesystem */ - mutex_lock (&ulfs_lock); + pthread_mutex_lock (&ulfs_lock); /*Store the specified port in the node */ node->nn->port = underlying; @@ -142,12 +142,12 @@ error_t node_init_root (mach_port_t underlying, /*the port to the LOG_MSG ("node_init_root: Could not stat the root node."); /*unlock the mutex and exit */ - mutex_unlock (&ulfs_lock); + pthread_mutex_unlock (&ulfs_lock); return err; } /*Release the lock for operations on the undelying filesystem */ - mutex_unlock (&ulfs_lock); + pthread_mutex_unlock (&ulfs_lock); /*Return the result of operations */ return err; @@ -72,7 +72,7 @@ typedef struct node node_t; /*---------------------------------------------------------------------------*/ /*--------Global Variables---------------------------------------------------*/ /*The lock protecting the underlying filesystem*/ -extern struct mutex ulfs_lock; +extern pthread_mutex_t ulfs_lock; /*---------------------------------------------------------------------------*/ /*---------------------------------------------------------------------------*/ |