Fix possible race bug of a crash observed
* src/mail.cpp (Mail::close_all_mails): Check for valididy of mail object before closing.
I observed a deleted mail beeing closed and then it crashed.
No idea how this could happen but this saveguard might help.