Fix memory issues.
Add support for iOS7/OSX10.9 bonjour peer to peer connectivity.