sebb 2004/01/07 17:13:38
Modified: src/protocol/http/org/apache/jmeter/protocol/http/sampler
HTTPSampler.java
Log:
Make compliant with JDK1.3
Revision Changes Path
1.78 +17 -14
jakarta-jmeter/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler.java
Index: HTTPSampler.java
===================================================================
RCS file:
/home/cvs/jakarta-jmeter/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler.java,v
retrieving revision 1.77
retrieving revision 1.78
diff -u -r1.77 -r1.78
--- HTTPSampler.java 20 Dec 2003 16:51:15 -0000 1.77
+++ HTTPSampler.java 8 Jan 2004 01:13:38 -0000 1.78
@@ -862,17 +862,20 @@
}
catch (IOException e)
{
- if (e.getCause() instanceof FileNotFoundException)
- {
- log.warn(e.getCause().toString());
- }
- else
+ //TODO: try to improve error discrimination when using JDK1.3
+ // and/or conditionally call .getCause()
+
+ //JDK1.4: if (e.getCause() instanceof FileNotFoundException)
+ //JDK1.4: {
+ //JDK1.4: log.warn(e.getCause().toString());
+ //JDK1.4: }
+ //JDK1.4: else
{
log.error(e.toString());
- Throwable cause = e.getCause();
- if (cause != null){
- log.error("Cause: "+cause);
- }
+ //JDK1.4: Throwable cause = e.getCause();
+ //JDK1.4: if (cause != null){
+ //JDK1.4: log.error("Cause: "+cause);
+ //JDK1.4: }
logError=true;
}
in= new BufferedInputStream(conn.getErrorStream());
@@ -880,10 +883,10 @@
catch (Exception e)
{
log.error(e.toString());
- Throwable cause = e.getCause();
- if (cause != null){
- log.error("Cause: "+cause);
- }
+ //JDK1.4: Throwable cause = e.getCause();
+ //JDK1.4: if (cause != null){
+ //JDK1.4: log.error("Cause: "+cause);
+ //JDK1.4: }
in= new BufferedInputStream(conn.getErrorStream());
logError=true;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]