exit gracefully?

"Jens Tinfors" <[email protected]> Thu, 18 Jan 2007 15:28:05 +0100
Newsgroups gmane.comp.voip.nist-sip
Message-ID <[email protected]>
hi,

I can't quite figure out how to exit or should I say uninitialize
gracefully in my Jain-SIP based app.

In my app I execute the following when I want to exit:
headerFactory = null;

addressFactory = null;

messageFactory = null;

sipFactory.resetFactory();
sipStack.deleteListeningPoint(listeningPoint);
sipProvider.removeListeningPoint(listeningPoint);
sipProvider.removeListeningPoint(listeningPoint_UDP);
sipStack.deleteSipProvider(sipProvider);
sipProvider = null;

sipFactory = null;

sipStack = null;

But still it hangs instead of exits.. Have I overlooked something here?

thanks
/j =)