In db.c, around line 1081, there's a call to db_message_set_unique_id that gets a FATAL trace if it returns non-zero. It's marked with a FIXME. Is there some reason why this should be a fatal error?
Would it be possible to wrap the db_update_message function, or better yet, dbmail_message_store in dbmail-message.c, in a transaction? Aaron