$NetBSD: patch-ab,v 1.4 2006/08/07 23:46:23 wiz Exp $

--- src/xmms-mad.c.orig	2004-05-16 16:54:38.000000000 +0000
+++ src/xmms-mad.c
@@ -144,6 +144,9 @@ xmmsmad_stop ()
       g_message ("waiting for thread");
 #endif /* DEBUG */
       pthread_join (*decode_thread, 0);
+#ifdef _PTH_PTHREAD_H_
+      sched_yield ();
+#endif
 #ifdef DEBUG
       g_message ("thread done");
 #endif /* DEBUG */
@@ -185,6 +188,9 @@ xmmsmad_play_file (char *url)
       g_free (decode_thread);
       decode_thread = 0;
     }
+#ifdef _PTH_PTHREAD_H_
+      sched_yield ();
+#endif
 }
 
 static void
