fix nick handling

fixes #50

 * only auto-retry-nick change when connecting
 * serialize new nick to db when it is changed successfully
 * don't count a client's NICK command as successfully changing the
   nick
IPv6 support

also, don't re-query all addresses after each failed address