• 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: crash when Notifier installed
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: crash when Notifier installed


  • Subject: Re: crash when Notifier installed
  • From: Quinn <email@hidden>
  • Date: Wed, 9 Jul 2003 08:27:48 +0100

At 14:16 -0700 25/6/03, michael ferraro wrote:
I have been trying to move some OT networking code to Carbon and find that
I crash as soon as my YieldingNotifier is called. The code I am recompiling
worked fine under OS 9.2.2. and was compiled uisng MW CW 6.

Carbon code that installs an OT notifier must pass in a UPP (an OTNotifyUPP), created using NewOTNotifyUPP. An OTNotifyUPP is just a simple function pointer on traditional Mac OS and on Mac OS X when you're built Mach-O. However, if you're running on Mac OS X and you're built CFM, an OTNotifyUPP wraps the glue that allows the Mach-O Open Transport compatibility library to call back to your CFM notifier.

So, instead of:

err = OTInstallNotifier(ep, YieldingNotifier, NULL);

you would use:

static OTNotifyUPP gYieldingNotifierUPP = NULL;

if (gYieldingNotifierUPP == NULL) {
gYieldingNotifierUPP = NewOTNotifyUPP(YieldingNotifier);
}
err = OTInstallNotifier(ep, gYieldingNotifierUPP, NULL);

S+E
--
Quinn "The Eskimo!" <http://www.apple.com/developer/>
Apple Developer Technical Support * Networking, Communications, Hardware
_______________________________________________
macnetworkprog mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/macnetworkprog
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Re: InternetConfig and Mac OS X - what are the valid keys?
  • Next by Date: Re: Implementation of BSD Socket for Network Communication
  • Previous by thread: Re: InternetConfig and Mac OS X - what are the valid keys?
  • Next by thread: Re: crash when Notifier installed
  • Index(es):
    • Date
    • Thread