Project

General

Profile

Actions

Defect #18922

closed

rdm-mailhandler.rb should catch EOFError

Added by Go MAEDA about 9 years ago. Updated about 9 years ago.

Status:
Closed
Priority:
Normal
Category:
Email receiving
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
Resolution:
Fixed
Affected version:

Description

rdm-mailhandler.rb should catch EOFError in addition to SystemCallError at source:trunk/extra/mail_handler/rdm-mailhandler.rb@13872#L132.

If communications between rdm-mailhandler.rb and Redmine are terminated while rdm-mailhandler.rb talking to Redmine, Net::HTTP raises EOFError and rdm-mailhandler stops unexpectedly because it does not catch EOFError. The email will be bounced.

error mail from MTA

We can avoid the preceding by this patch. The email will be deferred, not bounced.


Files

catch-EOFError.diff (669 Bytes) catch-EOFError.diff Go MAEDA, 2015-01-21 09:44
catch-IOError.diff (668 Bytes) catch-IOError.diff Go MAEDA, 2015-02-01 03:16
Actions #1

Updated by Jean-Philippe Lang about 9 years ago

Maybe we could even catch IOError which is the superclass of EOFError?

Actions #2

Updated by Go MAEDA about 9 years ago

Jean-Philippe Lang wrote:

Maybe we could even catch IOError which is the superclass of EOFError?

Indeed. To deal with a variety of situations, catching IOError is better solition.
Thank you for pointing it out.

Actions #3

Updated by Go MAEDA about 9 years ago

Here is a new patch. Catches IOError instead of EOFError.

Actions #4

Updated by Jean-Philippe Lang about 9 years ago

  • Status changed from New to Resolved
  • Assignee set to Jean-Philippe Lang
  • Target version set to 2.6.2
  • Resolution set to Fixed

Patch committed in r13961, thanks.

Actions #5

Updated by Jean-Philippe Lang about 9 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF