From c282afbf742f91ebd8b243c65017a5e33c6cb31d Mon Sep 17 00:00:00 2001 From: Jerry Cao Date: Fri, 08 Apr 2011 19:21:48 +0000 Subject: Use system pthread library --- diff --git a/libfuse-lite/fuse_misc.h b/libfuse-lite/fuse_misc.h index 5f02165..8630989 100755 --- a/libfuse-lite/fuse_misc.h +++ b/libfuse-lite/fuse_misc.h @@ -22,61 +22,6 @@ static inline void fuse_mutex_init(pthread_mutex_t *mut) } #endif -typedef struct _pthread_rwlock_t -{ -// struct _pthread_fastlock __rw_lock; /* Lock to guarantee mutual exclusion */ - int __rw_readers; /* Number of readers */ -// _pthread_descr __rw_writer; /* Identity of writer, or NULL if none */ -// _pthread_descr __rw_read_waiting; /* Threads waiting for reading */ -// _pthread_descr __rw_write_waiting; /* Threads waiting for writing */ - int __rw_kind; /* Reader/Writer preference selection */ - int __rw_pshared; /* Shared between processes or not */ -} pthread_rwlock_t; - -typedef struct -{ - int __lockkind; - int __pshared; -} pthread_rwlockattr_t; - - -static inline int pthread_rwlock_init (pthread_rwlock_t * __rwlock, - pthread_rwlockattr_t *__attr) -{ - return 1; -} - -static inline int pthread_rwlock_destroy (pthread_rwlock_t *__rwlock) -{ - return 1; -} - - - -/* Acquire read lock for RWLOCK. */ -static inline int pthread_rwlock_rdlock (pthread_rwlock_t *__rwlock) -{ - return 1; -} - - -/* Acquire write lock for RWLOCK. */ -static inline int pthread_rwlock_wrlock (pthread_rwlock_t *__rwlock) -{ - return 1; -} - - - - -/* Unlock RWLOCK. */ -static inline int pthread_rwlock_unlock (pthread_rwlock_t *__rwlock) -{ - return 1; -} - - - #ifdef HAVE_STRUCT_STAT_ST_ATIM /* Linux */ #define ST_ATIM_NSEC(stbuf) ((stbuf)->st_atim.tv_nsec) -- cgit