Re: [AD] Patch to fix race condition |
[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
- To: "Coordination of admins/developers of the game programming library Allegro" <alleg-developers@xxxxxxxxxx>
- Subject: Re: [AD] Patch to fix race condition
- From: "Trent Gamblin" <trent@xxxxxxxxxx>
- Date: Sun, 28 Feb 2010 22:19:57 -0700 (MST)
On Sun, February 28, 2010 9:43 pm, Evert Glebbeek said:
> I didn't read this very carefully, but is this similar to the issue on OS X I fixed a short while
> back, where trying to set errno (because allegro.cfg isn't found) before TLS was initialised
> caused some memory corruption (due to an invalid TLS being read back) that sometimes lead to a
> crash later on?
> I fixed that by calling the TLS initialisation routine in the system driver before anything else.
> There's even a CMake option for it (which was already there).
Yes, it's exactly like that. Setting ALLEGRO_CFG_PTHREADS_TLS=1 in the iPhone xcode project
fixes it too. This is probably the best of all the solutions so I will probably commit it.
Trent :{)>