Christian Costa <[EMAIL PROTECTED]> writes:
> Alexandre Julliard wrote:
>
>>This isn't thread-safe.
>>
> The function that uses them is a timer callback.
You are right, this doesn't matter then.
> Well, I intended, in later patches, to update the poll fds when
> opening or closing devices and th
Alexandre Julliard wrote:
Christian Costa <[EMAIL PROTECTED]> writes:
+static int npfd;
+static int pfd_array_size = 0;
+static struct pollfd *pfd = NULL;
This isn't thread-safe.
The function that uses them is a timer callback.
Why don't you simply allocate the array in the
function and
Christian Costa <[EMAIL PROTECTED]> writes:
> +static int npfd;
> +static int pfd_array_size = 0;
> +static struct pollfd *pfd = NULL;
This isn't thread-safe. Why don't you simply allocate the array in the
function and free it when you are done?
--
Alexandre Julliard
[EMAIL PROTECTED]
Eric Pouech wrote:
Christian Costa a écrit :
+for (wDevID = 0; wDevID < MIDM_NumDevs; wDevID++)
+if ( (ev->source.client == MidiInDev[wDevID].addr.client) &&
(ev->source.client == MidiInDev[wDevID].addr.client) )
+break;
Why do you do twice the same test ?
A+
Indeed this is
Christian Costa a écrit :
+ for (wDevID = 0; wDevID < MIDM_NumDevs; wDevID++)
+ if ( (ev->source.client == MidiInDev[wDevID].addr.client) &&
(ev->source.client == MidiInDev[wDevID].addr.client) )
+ break;
Why do you do twice the same test ?
A+
Marcus Meissner wrote:
On Fri, Jan 09, 2004 at 12:03:10PM +, Mike Hearn wrote:
On Thu, 08 Jan 2004 16:46:53 -0800, Alexandre Julliard wrote:
You should not use alloca in Wine, it's not portable enough.
Could we take the glib implementation of alloca and stick it into
libwine_por
On Fri, Jan 09, 2004 at 12:03:10PM +, Mike Hearn wrote:
> On Thu, 08 Jan 2004 16:46:53 -0800, Alexandre Julliard wrote:
> > You should not use alloca in Wine, it's not portable enough.
>
> Could we take the glib implementation of alloca and stick it into
> libwine_port? IIRC in glib it uses th
On Thu, 08 Jan 2004 16:46:53 -0800, Alexandre Julliard wrote:
> You should not use alloca in Wine, it's not portable enough.
Could we take the glib implementation of alloca and stick it into
libwine_port? IIRC in glib it uses the system implementation unless it's
not good enough or missing, in whi
Christian Costa <[EMAIL PROTECTED]> writes:
> +int npfd;
> +struct pollfd *pfd;
> +
> +npfd = snd_seq_poll_descriptors_count(midiSeq, POLLIN);
> +pfd = (struct pollfd *)alloca(npfd * sizeof(struct pollfd));
You should not use alloca in Wine, it's not portable enough.
--
Alex