[Lazarus] custom thread reading file does not respond properly

Mark Morgan Lloyd markMLl.lazarus at telemetry.co.uk
Tue Sep 5 18:44:45 CEST 2017


On 05/09/17 13:00, Andrea Mauri via Lazarus wrote:
> Dear all,
> I have an issue using threads on OSX.Basically I have a thread reading a 
> file and looking for a string match.I have no problem on win and linux 
> but on osx my thread updates the form but my application does not 
> respond.I opened a topic on the forum 
> (https://forum.lazarus.freepascal.org/index.php/topic,38146.0.html), I 
> would like a more satisfactory answer. I am trying here.
> If possible, I would like to understand if this behaviour is related to 
> OSX or SSD drive. If related to OSX I can simply add IFDEF DARWIN 
> calling sleep?If it is related to SSD how can I manage it?

James Richters on the fpc-pascal ML commented on SSD commit problems in 
March. However I don't see why something like that should spill over to 
the UI.

I notice that multiple people have already told you not to use a tight 
loop, and that applies to any OS.

-- 
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]


More information about the Lazarus mailing list