basic Presence for XMPP & better error handling

Support for basic Presence with <show> is added.

Error handling got improved by adding error handling with Fprintf, and
by handling unexpected XMPP message in Recv().
Sending the full stanza, or report an error.

It turned out that partial send may cause perpetual inability to
recover during the session, which is a serious issue worthy of an
error. So, always try full send, and only treat errors reported during
sending as real errors, but not partial send.