jmeter-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pmoua...@apache.org
Subject svn commit: r1302019 - /jmeter/trunk/src/protocol/mail/org/apache/jmeter/protocol/smtp/sampler/SmtpSampler.java
Date Sat, 17 Mar 2012 21:50:28 GMT
Author: pmouawad
Date: Sat Mar 17 21:50:27 2012
New Revision: 1302019

URL: http://svn.apache.org/viewvc?rev=1302019&view=rev
Log:
Factor code between exceptions.
Make sampler fail if Exception occurs (not only AddressException, IOException, MessagingException)

Modified:
    jmeter/trunk/src/protocol/mail/org/apache/jmeter/protocol/smtp/sampler/SmtpSampler.java

Modified: jmeter/trunk/src/protocol/mail/org/apache/jmeter/protocol/smtp/sampler/SmtpSampler.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/protocol/mail/org/apache/jmeter/protocol/smtp/sampler/SmtpSampler.java?rev=1302019&r1=1302018&r2=1302019&view=diff
==============================================================================
--- jmeter/trunk/src/protocol/mail/org/apache/jmeter/protocol/smtp/sampler/SmtpSampler.java
(original)
+++ jmeter/trunk/src/protocol/mail/org/apache/jmeter/protocol/smtp/sampler/SmtpSampler.java
Sat Mar 17 21:50:27 2012
@@ -191,17 +191,7 @@ public class SmtpSampler extends Abstrac
                 res.setBytes(-1);
             }
 
-        } catch (AddressException ex) {
-            log.warn("Error while preparing message", ex);
-            res.setResponseCode("500");
-            res.setResponseMessage(ex.toString());
-            return res;
-        } catch (IOException ex) {
-            log.warn("Error while preparing message", ex);
-            res.setResponseCode("500");
-            res.setResponseMessage(ex.toString());
-            return res;
-        } catch (MessagingException ex) {
+        } catch (Exception ex) {
             log.warn("Error while preparing message", ex);
             res.setResponseCode("500");
             res.setResponseMessage(ex.toString());



Mime
View raw message