<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type"/>
<title></title>
</head>
<body>
<p style="margin: 0px;"><span> </span></p>
<p style="margin: 0px;"> </p>
<div style="margin: 5px 0px 5px 0px;">
Henry Vermaak <henry.vermaak@gmail.com> hat am 9. Juni 2011 um 12:12 geschrieben:<br/>
<br/>
> On 09/06/11 11:01, Mattias Gaertner wrote:<br/>
> ><br/>
> ><br/>
> > Michael Schnell <mschnell@lumino.de> hat am 9. Juni 2011 um 11:46<br/>
> > geschrieben:<br/>
> ><br/>
> > > On 06/09/2011 10:58 AM, Henry Vermaak wrote:<br/>
> > > > You will corrupt the linked list that QueueAsyncCall() uses when you<br/>
> > > > call it from multiple threads, so you _must_ protect it.<br/>
> > > As QueueAsyncCall is specified exactly for this use, it needs to take<br/>
> > > care of this issue internally. Otherwise it obviously is buggy. I trust<br/>
> > > that the LCL developers did a decent job.<br/>
> ><br/>
> > The only "specification" I found for TApplication.QueueAsyncCall is the<br/>
> > fpdoc entry:<br/>
> ><br/>
> > Insert a given asynchronous call into the queue<br/>
> ><br/>
> > Why do you think it is thread safe?<br/>
><br/>
> Do you propose that QueueAsyncCall throws an exception if it's used from<br/>
> outside the main thread? Otherwise adding a critical section to all the<br/>
> async queue methods is in order.
</div><br/>
I made it thread safe. Please test.<br/>
<br/>
Mattias<br/>
<br/>
</body>
</html>