Re: Unvending a DO?
Re: Unvending a DO?
- Subject: Re: Unvending a DO?
- From: "Rafael K. Kobylinski" <email@hidden>
- Date: Sat, 16 Mar 2002 00:50:33 +0100
At 19:58 Uhr -0800 14.03.2002, Lisa Zorn wrote:
[vendingConnection_ invalidate];
[vendingConnection_ release];
I have observed that if I invalidate the connection on my client
before releasing it, the server will not notice (no
NSConnectionDidDieNotification) that the client is gone. If I release
the connection without invalidating it, then the server gets a
NSConnectionDidDieNotification.
I have also observed that invalidating a vended connection based on
NSSocketPort does not prevent me from telnet'ing to that port, while
releasing the NSConnection without invalidating will close the
listening port immediately.
This solution does not feel right, though. I did not find any
examples on "unveding" a DO in an orderly fashion. The
TrivialThreads/SimpleThreads sample code unfortunately omits this
issue.
One thing that I could not get to work is to get rid of the
connection in a clean manner when the client quits. While, as
described above, just releasing the connection usually works, for
some reason it does not work in my applicationShouldTerminate:
implementation.
--
Rafael K. Kobylinski Email: email@hidden
Institut f|r Informatik Tel. : ++ 49 89 289 22391
Technische Universitdt M|nchen Cell.: ++ 49 177 7 495020
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.