summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndreas Baumann <abaumann@yahoo.com>2009-03-30 19:29:44 +0200
committerAndreas Baumann <abaumann@yahoo.com>2009-03-30 19:29:44 +0200
commit3f9d2fe1837a11b70a6949304e192e977ff8b9d0 (patch)
tree0da4206165099517e6b2dede22d118ed2dc27a82 /src
parent7bf88dd4cdba8e069384942581e92213316d59b0 (diff)
downloadwolfbones-3f9d2fe1837a11b70a6949304e192e977ff8b9d0.tar.gz
wolfbones-3f9d2fe1837a11b70a6949304e192e977ff8b9d0.tar.bz2
fixed severe bux in mutex handling and tested strerror_r on Cygwin
Diffstat (limited to 'src')
-rw-r--r--src/mutex.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mutex.c b/src/mutex.c
index 2e06318..5aa18cf 100644
--- a/src/mutex.c
+++ b/src/mutex.c
@@ -33,7 +33,7 @@ wolf_error_t wolf_mutex_init( wolf_mutex_t *mutex ) {
return WOLF_ERR_OUT_OF_MEMORY;
} else if( res == EINVAL ) {
return WOLF_ERR_INVALID_VALUE;
- } else {
+ } else if( res != 0 ) {
return WOLF_ERR_INTERNAL;
}
@@ -51,7 +51,7 @@ wolf_error_t wolf_mutex_init( wolf_mutex_t *mutex ) {
return WOLF_ERR_OUT_OF_MEMORY;
} else if( res == EINVAL ) {
return WOLF_ERR_INVALID_VALUE;
- } else {
+ } else if( res != 0 ) {
return WOLF_ERR_INTERNAL;
}
@@ -68,7 +68,7 @@ wolf_error_t wolf_mutex_destroy( wolf_mutex_t *mutex ) {
res = pthread_mutex_destroy( mutex );
if( res == EINVAL ) {
return WOLF_ERR_INVALID_VALUE;
- } else {
+ } else if( res != 0 ) {
return WOLF_ERR_INTERNAL;
}