Catch exceptions when processing headers of upload request