All pastes #1221054 Raw Edit

Miscellany

public text v1 · immutable
#1221054 ·published 2008-10-06 21:08 UTC
rendered paste body
Index: libhb/ports.c
===================================================================
--- libhb/ports.c	(revision 1816)
+++ libhb/ports.c	(working copy)
@@ -409,7 +409,12 @@
 #if defined( SYS_BEOS )
     l->sem = create_sem( 1, "sem" );
 #elif USE_PTHREAD
-    pthread_mutex_init( &l->mutex, NULL );
+    pthread_mutexattr_t mta;
+
+    pthread_mutexattr_init(&mta);
+    pthread_mutexattr_settype(&mta, PTHREAD_MUTEX_NORMAL);
+
+    pthread_mutex_init( &l->mutex, &mta );
 //#elif defined( SYS_CYGWIN )
 //    l->mutex = CreateMutex( 0, FALSE, 0 );
 #endif