[C con Clase] problemas al usar fork() en un programa

Leonel Florin Selles leonel06033 en cfg.jovenclub.cu
Lun Dic 13 22:55:36 CET 2010


Hola amigos:

Tengo un porgrama que esta destinado a hacer un demonio, pero este
programa va a chequear varias cosas en el sistema y si una de estas cosas
sucede pues tendra que reproducir un sonido wav, para esto ultimo estoy
utilizando SDL_MIX, pero cuando ejecuto fork() sobre el programa pues no
reproduce nada, y si inicializa todo bien, pero no reproduce que será
amigos.

saludos.

Hi friends:

Well, i'm developing a program create with C++, this program is a daemon,
i mean, the program will start in the background when the system start
(linux), this daemon will check a several things on the system and if some
of these things that the program will check happens the daemon have to
play a sound, for this i'm using SDL_Mixer, and if I execute the program
manually he play the sound (wav), but if I put th program in daemon form
when he try to init de SDL_mixer he get out and stop working.

My question is, is possible that I can not use the SDL_mixer for do this
from a program when is a daemon?.






Más información sobre la lista de distribución Cconclase