• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Closing an IOUserClient
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Closing an IOUserClient


  • Subject: Re: Closing an IOUserClient
  • From: Shaun Wexler <email@hidden>
  • Date: Wed, 19 Dec 2007 17:02:59 -0800

On Dec 19, 2007, at 11:22 AM, Duane Murphy wrote:

SimpleUserClient works just fine when the user side closes the
connection. I want to close the connect _from_ the provider.

That is, the provider is tracking user clients and has determined that
the user client needs to be closed, what do I do?

I am having some luck with terminate() but some things still seem like
they are not working correctly.

In the provider, if (userClient->terminate(this, options)) ...

Your userclient must maintain its own state and + retain count while it's being torn down in phases. This means the user-space clients watch for their service being terminated, and close their connections immediately. The userclient should delay its teardown during didTerminate(), and call that function itself once all clients have been closed, which will then cause the stop thread to be scheduled.

~HTH
--
Shaun Wexler
MacFOH
http://www.macfoh.com


Attachment: smime.p7s
Description: S/MIME cryptographic signature

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Closing an IOUserClient (From: "Duane Murphy" <email@hidden>)
 >Re: Closing an IOUserClient (From: "Duane Murphy" <email@hidden>)
 >Re: Closing an IOUserClient (From: Garth Cummings <email@hidden>)
 >Re: Closing an IOUserClient (From: "Duane Murphy" <email@hidden>)

  • Prev by Date: Re: HowTo: catch a signal and get a CrashLog too (Leopard)
  • Next by Date: Re: HowTo: catch a signal and get a CrashLog too (Leopard)
  • Previous by thread: Re: Closing an IOUserClient
  • Next by thread: Java JNI
  • Index(es):
    • Date
    • Thread