gnustep-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Notification centre and threads


From: Richard Frith-Macdonald
Subject: Re: Notification centre and threads
Date: Fri, 27 Nov 2009 17:59:11 +0000

On 27 Nov 2009, at 17:43, Richard Frith-Macdonald wrote:

> 
> On 27 Nov 2009, at 17:22, David Chisnall wrote:
> 
>> Hi,
>> 
>> I've noticed a couple of places in the GNUstep source where the 
>> NSNotificationCentre is cached the first time a class is created and then 
>> used by all instances.  With the documented behaviour for the notification 
>> centre on OS X, this will do undefined things when the instance is not in 
>> the same thread as the one where the notification centre was created.  Does 
>> GNUstep have some special logic for handling cross-thread notifications (and 
>> is this documented somewhere) or are all of these uses potential bugs?
> 
> I'm not sure ... I think NSNotificationCenter is thread-safe in GNUstep ... 
> what problems would that cause?

I had a quick look at the current OSX documentation for the class, and I didn't 
see anything saying that it 'will do undefined things when the instance is not 
in the same thread as the one where the notification centre was created' ... 
what did I miss?





reply via email to

[Prev in Thread] Current Thread [Next in Thread]