Commit 90b71b51 authored by Eric Pouech's avatar Eric Pouech Committed by Alexandre Julliard

Fixed multi-thread access to local variables (mainly fd for

/dev/dsp). God rid of obsolete macro. Fixed some slight init issues.
parent ef1f0156
...@@ -217,7 +217,8 @@ BOOL OSS_MidiInit(void) ...@@ -217,7 +217,8 @@ BOOL OSS_MidiInit(void)
* it's probably equal or more than wVoices * it's probably equal or more than wVoices
*/ */
tmplpCaps->wNotes = sinfo.nr_voices; tmplpCaps->wNotes = sinfo.nr_voices;
tmplpCaps->wChannelMask= 0xFFFF;
/* FIXME Do we have this information? /* FIXME Do we have this information?
* Assuming the soundcards can handle * Assuming the soundcards can handle
* MIDICAPS_VOLUME and MIDICAPS_LRVOLUME but * MIDICAPS_VOLUME and MIDICAPS_LRVOLUME but
...@@ -231,10 +232,10 @@ BOOL OSS_MidiInit(void) ...@@ -231,10 +232,10 @@ BOOL OSS_MidiInit(void)
FIXME("Synthesizer support MIDI in. Not supported yet (please report)\n"); FIXME("Synthesizer support MIDI in. Not supported yet (please report)\n");
} }
TRACE("name='%s', techn=%d voices=%d notes=%d support=%ld\n", TRACE("SynthOut[%d]\tname='%s' techn=%d voices=%d notes=%d chnMsk=%04x support=%ld\n"
tmplpCaps->szPname, tmplpCaps->wTechnology, "\tOSS info: synth subtype=%d capa=%lx\n",
tmplpCaps->wVoices, tmplpCaps->wNotes, tmplpCaps->dwSupport); i, tmplpCaps->szPname, tmplpCaps->wTechnology, tmplpCaps->wVoices,
TRACE("OSS info: synth subtype=%d capa=%lx\n", tmplpCaps->wNotes, tmplpCaps->wChannelMask, tmplpCaps->dwSupport,
sinfo.synth_subtype, (long)sinfo.capabilities); sinfo.synth_subtype, (long)sinfo.capabilities);
} }
...@@ -292,12 +293,14 @@ BOOL OSS_MidiInit(void) ...@@ -292,12 +293,14 @@ BOOL OSS_MidiInit(void)
tmplpOutCaps->wVoices = 16; tmplpOutCaps->wVoices = 16;
/* Does it make any difference? */ /* Does it make any difference? */
tmplpOutCaps->wNotes = 16; tmplpOutCaps->wNotes = 16;
tmplpOutCaps->wChannelMask= 0xFFFF;
/* FIXME Does it make any difference? */ /* FIXME Does it make any difference? */
tmplpOutCaps->dwSupport = MIDICAPS_VOLUME|MIDICAPS_LRVOLUME; tmplpOutCaps->dwSupport = MIDICAPS_VOLUME|MIDICAPS_LRVOLUME;
midiOutDevices[numsynthdevs + i] = tmplpOutCaps; midiOutDevices[numsynthdevs + i] = tmplpOutCaps;
tmplpInCaps = HeapAlloc(GetProcessHeap(), 0, sizeof(MIDIOUTCAPSA)); tmplpInCaps = HeapAlloc(GetProcessHeap(), 0, sizeof(MIDIINCAPSA));
if (!tmplpInCaps) if (!tmplpInCaps)
break; break;
/* This whole part is somewhat obscure to me. I'll keep trying to dig /* This whole part is somewhat obscure to me. I'll keep trying to dig
...@@ -318,10 +321,13 @@ BOOL OSS_MidiInit(void) ...@@ -318,10 +321,13 @@ BOOL OSS_MidiInit(void)
midiInDevices[i] = tmplpInCaps; midiInDevices[i] = tmplpInCaps;
TRACE("name='%s' techn=%d voices=%d notes=%d support=%ld\n", TRACE("MidiOut[%d]\tname='%s' techn=%d voices=%d notes=%d chnMsk=%04x support=%ld\n"
tmplpOutCaps->szPname, tmplpOutCaps->wTechnology, tmplpOutCaps->wVoices, "MidiIn [%d]\tname='%s' support=%ld\n"
tmplpOutCaps->wNotes, tmplpOutCaps->dwSupport); "\tOSS info: midi dev-type=%d, capa=%lx\n",
TRACE("OSS info: midi dev-type=%d, capa=%lx\n", i, tmplpOutCaps->szPname, tmplpOutCaps->wTechnology,
tmplpOutCaps->wVoices, tmplpOutCaps->wNotes,
tmplpOutCaps->wChannelMask, tmplpOutCaps->dwSupport,
i, tmplpInCaps->szPname, tmplpInCaps->dwSupport,
minfo.dev_type, (long)minfo.capabilities); minfo.dev_type, (long)minfo.capabilities);
} }
......
...@@ -33,12 +33,6 @@ ...@@ -33,12 +33,6 @@
#include <sys/errno.h> #include <sys/errno.h>
#endif #endif
#ifdef SOUND_VERSION
#define IOCTL(a,b,c) ioctl(a,b,&c)
#else
#define IOCTL(a,b,c) (c = ioctl(a,b,c))
#endif
extern LONG OSS_WaveInit(void); extern LONG OSS_WaveInit(void);
extern BOOL OSS_MidiInit(void); extern BOOL OSS_MidiInit(void);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment