[fpc-devel] Rather large flaw in TJSONConfig component

Graeme Geldenhuys graemeg.lists at gmail.com
Tue Jun 22 11:29:16 CEST 2010


Op 2010-06-22 11:17, Henry Vermaak het geskryf:
>>
>> My point is that this is the wrong place to build such functionality
>> in.  How do you propose this should work from different files or
>> processes?
> 
> s/files/threads

In tiOPF we have a Singleton for INI file processing. It uses the
TMultiReadExclusiveWriteSynchronizer class no manage access, and it is
thread-safe.

FPC finally has a working TMultiReadExclusiveWriteSynchronizer
implementation (tiOPF implemented it's own), but I don't know if that
implementation is available for FPC 2.4.x yet, or if it is still only in
Trunk.  Either way, TXXXConfig classes could use the same synchronizer to
manage access - with a bit of refactoring.


Regards,
  - Graeme -

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://opensoft.homeip.net/fpgui/




More information about the fpc-devel mailing list