blob: a57b7401a385c966da22cbc9e29f1ea3572c3ced (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
$NetBSD: patch-aa,v 1.4 2006/08/07 23:46:23 wiz Exp $
--- src/decoder.c.orig 2004-05-16 17:08:05.000000000 +0000
+++ src/decoder.c
@@ -274,6 +274,9 @@ decode (void *arg)
/* main loop */
do
{
+#ifdef _PTH_PTHREAD_H_
+ sched_yield();
+#endif
if (info->stop)
break;
if (seek_skip)
@@ -430,6 +433,8 @@ decode (void *arg)
#endif /* DEBUG */
mad_plugin.output->close_audio ();
+ close (info->infile);
+ info->infile = 0;
info->stop = 1;
pthread_exit (0);
}
|