Mix_OpenAudio crashes on Mandrake 9.2 when artsd is active

Hi!

When I run the following program:

<<<
#include “SDL.h”
#include “SDL_mixer.h”

int main()
{
// start SDL with audio support
if(SDL_Init(SDL_INIT_AUDIO)==-1) {
printf(“SDL_Init: %s\n”, SDL_GetError());
exit(1);
}
// open 44.1KHz, signed 16bit, system byte order,
// stereo audio, using 1024 byte chunks
if(Mix_OpenAudio(44100, MIX_DEFAULT_FORMAT, 2, 1024)==-1) {
printf(“Mix_OpenAudio: %s\n”, Mix_GetError());
exit(2);
}

return 0;

}

I get the following errors, and eventually the program crashes:

<<<
ALSA lib pcm_hw.c:1055:(snd_pcm_hw_open) open /dev/snd/pcmC0D0p failed:
Device or resource busy
mcop warning: user defined signal handler found for SIG_PIPE, overriding
Fatal signal: Segmentation Fault (SDL Parachute Deployed)

According to gdb, the problem occurs at:

<<<
Program received signal SIGSEGV, Segmentation fault.
0x409c2e67 in Arts::StartupManager::startup() () from
/usr/lib/libmcop.so.1
(gdb) bt
#0 0x409c2e67 in Arts::StartupManager::startup() () from
/usr/lib/libmcop.so.1
#1 0x406c2010 in Arts::The_WaveDataHandle_impl_Factory ()
from /usr/lib/libartsflow.so.1

This problem makes me unable to play pysol or frozen-bubble when I hear
music in the background.

Regards,

Shlomi Fish----------------------------------------------------------------------

Shlomi Fish @Shlomi_Fish
Home Page: http://t2.technion.ac.il/~shlomif/

You are banished! You are banished! You are banished!

Hey? I’m just kidding!

Shlomi Fish wrote:

ALSA lib pcm_hw.c:1055:(snd_pcm_hw_open) open /dev/snd/pcmC0D0p failed:
Device or resource busy
mcop warning: user defined signal handler found for SIG_PIPE, overriding

You didn’t run you program in gdb, did you?

This problem makes me unable to play pysol or frozen-bubble when I hear
music in the background.

Did you set SDL_AUDIODRIVER to “arts”? The device itself is, of course,
busy when you’re running artsd. Nonetheless, this might be a bug, there
shouldn’t be a SIGSEGV.–
Christian
-------------- next part --------------
A non-text attachment was scrubbed…
Name: not available
Type: application/pgp-signature
Size: 186 bytes
Desc: not available
URL: http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20040118/08497c8a/attachment.pgp

Shlomi Fish wrote:

ALSA lib pcm_hw.c:1055:(snd_pcm_hw_open) open /dev/snd/pcmC0D0p failed:
Device or resource busy
mcop warning: user defined signal handler found for SIG_PIPE, overriding

You didn’t run you program in gdb, did you?

I ran it both in gdb and outside it.

This problem makes me unable to play pysol or frozen-bubble when I hear
music in the background.

Did you set SDL_AUDIODRIVER to “arts”? The device itself is, of course,
busy when you’re running artsd. Nonetheless, this might be a bug, there
shouldn’t be a SIGSEGV.

When setting SDL_AUDIODRIVER to arts both apps run, but without sound.

I should note that I’m using it with:

libSDL1.2-1.2.5-12mdk
libSDL_mixer1.2-1.2.5-3mdk

This is due to the fact that I was unable to compile the vanilla SDL on my
system. (more of that in another message).

Regards,

Shlomi FishOn Sun, 18 Jan 2004, Christian Biere wrote:

Shlomi Fish @Shlomi_Fish
Home Page: http://t2.technion.ac.il/~shlomif/

You are banished! You are banished! You are banished!

Hey? I’m just kidding!