LMTP/TIMSIEVE: fix possible segfaults
IMAP: fix inverted logic during abort