[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug #44240] NSThread leaks a run loop if NSFileHandle -finalize is call
From: |
Wolfgang Lux |
Subject: |
[bug #44240] NSThread leaks a run loop if NSFileHandle -finalize is called during deallocation |
Date: |
Tue, 17 Feb 2015 17:41:38 +0000 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_2) AppleWebKit/600.3.18 (KHTML, like Gecko) Version/8.0.3 Safari/600.3.18 |
Follow-up Comment #2, bug #44240 (project gnustep):
That change looks reasonable to me and fixes the problem.
However, I think that there's also an issue with the -ignoreReadDescriptor and
-ignoreWriteDescriptor methods from NSFileHandle. It looks fairly stupid to me
to create a new run loop for the current thread when are just about to delete
the thread and its run loop. But what looks worse to me is that this code will
remove the file descriptor from the run loop of the current thread only. It
doesn't handle the case where the file descriptor is added to the run loop of
a secondary thread, but then closed on the main thread (or vice versa). My
feeling is that if we call -removeEvent:type:forMode:all: we should do that
for all (and only those) run loops that currently exist.
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?44240>
_______________________________________________
Nachricht gesendet von/durch Savannah
http://savannah.gnu.org/