Support XEP-0198 session resumption

Implement the optional session resumption feature described in XEP-0198.
A client that supports this feature may now resume the previous session
(within a configurable number of seconds) if the connection was lost.
During resumption, ejabberd will retransmit any stanzas that hadn't been
acknowledged by the client.
Remove "fun" element from c2s #state

Memory consumption wise, local "fun" references are quite expensive.
XEP-0198: Bounce unacked stanzas by default

If the new "resend_on_timeout" option is set to false (which it is by
default), bounce any unacknowledged stanzas instead of re-routing them.