MOL release candidate available

Samuel Rydh mol-general@lists.maconlinux.org
Sun, 1 Feb 2004 22:12:46 +0100


On Sun, Feb 01, 2004 at 10:47:00PM +0100, Christian Jaeger wrote:
> Thanks Samuel, removing bison++, installing bison and touch'ing the 
> zconf-y.{y,l} source files made it compile.
> 
> But it doesn't run:
> 
> ***** SIGNAL 11 [Segmentation fault] in thread main-thread *****
>    si_signo = 11, si_errno 0, si_code 00000001, si_addr (nil)
>    Last RVEC: 0x0 (0), last OSI: 0, mac_nip FFF00100
>    NIP 0x0fbfda48
> ***** Backtrace *****
>    7ffff230: backtrace + 0x3c
>    7ffff250: signal_handler + 0x1a4
>    7ffff280: 0x0fd6f8d8
>    7ffff2b0: 0x7ffff608
>    7ffff900: get_str_res_ind + 0x18
>    7ffff910: osi_sound_init + 0x1b8
>    7ffff920: Letext + 0x34
>    7ffff930: ioports_init + 0x44
>    7ffff940: main + 0x1b8
>    7ffff960: 0x0fb99c30
>    7ffff990: 0x00000000
> cleaning up...
> Terminating threads...
> DONE
> 
> Any idea? Can I help somehow?
> 

I'm pretty sure I have found the bug. It occurs if

	- no "sound.driver" resource is specified
	- MOL does not find a usable sound device

The patch below should fix things.


===== osi_sound.c 1.30 vs edited =====
--- 1.30/src/drivers/osi_sound.c	Sun Jan 11 22:14:11 2004
+++ edited/osi_sound.c	Sun Feb  1 22:08:11 2004
@@ -1019,7 +1019,6 @@
 	/* select output driver */
 	for( i=0 ;; i++ ) {
 		char *s = get_str_res_ind("sound.driver", 0, i );
-		
 		if( i && !s )
 			break;
 		if( s && !strcasecmp("any", s) )
@@ -1028,8 +1027,10 @@
 			break;
 		if( (!s || !strcasecmp("oss", s) || !strcasecmp("dsp", s)) && (ss.ops=oss_probe(s?1:0)) )
 			break;
-		if( !strcasecmp("nosound", s) )
+		if( !s || !strcasecmp("nosound", s) ) {
 			ss.ops = &nosound_driver_ops;
+			break;
+		}
 	}
 	if( !ss.ops )
 		ss.ops = &nosound_driver_ops;