Handle deadlock in history_check().
Multi-threaded spool I/O.

When multiple threads are calling spool_store(), we can optimise by releasing
the spool_mtx before we do the actual I/O, as long as we increase sf->sf_size
by enough to make room for the article.  This allows multiple threads to write
to the spool file at once.

Only do this when !spool_do_sync, as otherwise articles can get written out
of order, and recovery becomes impossible to do reliably.