Merge pull request #796 from mannol1/master

Changed msi callbacks
Merge pull request #798 from mannol1/master

Fixed segfault, timeout handling and logging.
Detailed docs for TCP server pretty much done.

Implementation coming soon.
Started writing the code for the TCP relay server.
Fixed bug, unconfirmed friends now load correctly.
Slightly more work done on the TCP relay server.
A bit of work done on the TCP relay server.
Added new callback