mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-20 12:16:40 +00:00
Avoid possibility of stream deallocation while sending events.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@25004 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
c554c4045c
commit
4e2e9e93e3
2 changed files with 6 additions and 0 deletions
|
@ -564,6 +564,7 @@ static void setNonblocking(int fd)
|
|||
socklen_t len = sizeof(error);
|
||||
unsigned i = [_modes count];
|
||||
|
||||
AUTORELEASE(RETAIN(self));
|
||||
while (i-- > 0)
|
||||
{
|
||||
[_runloop removeStream: self mode: [_modes objectAtIndex: i]];
|
||||
|
@ -977,6 +978,7 @@ static void setNonblocking(int fd)
|
|||
int result;
|
||||
unsigned i = [_modes count];
|
||||
|
||||
AUTORELEASE(RETAIN(self));
|
||||
while (i-- > 0)
|
||||
{
|
||||
[_runloop removeStream: self mode: [_modes objectAtIndex: i]];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue