You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-dev@jakarta.apache.org by ju...@apache.org on 2002/02/06 18:01:33 UTC
cvs commit: jakarta-slide/src/webdav/client/src/org/apache/commons/httpclient HttpClient.java
juergen 02/02/06 09:01:33
Modified: src/webdav/client/src/org/apache/commons/httpclient
HttpClient.java
Log:
if a wrong user id/password is given, execute method will return now with a right response code (401) without throwing an exception.
Revision Changes Path
1.8 +5 -3 jakarta-slide/src/webdav/client/src/org/apache/commons/httpclient/HttpClient.java
Index: HttpClient.java
===================================================================
RCS file: /home/cvs/jakarta-slide/src/webdav/client/src/org/apache/commons/httpclient/HttpClient.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- HttpClient.java 28 Jan 2002 13:09:05 -0000 1.7
+++ HttpClient.java 6 Feb 2002 17:01:32 -0000 1.8
@@ -1,7 +1,7 @@
/*
- * $Header: /home/cvs/jakarta-slide/src/webdav/client/src/org/apache/commons/httpclient/HttpClient.java,v 1.7 2002/01/28 13:09:05 juergen Exp $
- * $Revision: 1.7 $
- * $Date: 2002/01/28 13:09:05 $
+ * $Header: /home/cvs/jakarta-slide/src/webdav/client/src/org/apache/commons/httpclient/HttpClient.java,v 1.8 2002/02/06 17:01:32 juergen Exp $
+ * $Revision: 1.8 $
+ * $Date: 2002/02/06 17:01:32 $
*
* ====================================================================
*
@@ -653,6 +653,8 @@
}
if (retries == 5) {
+ if (method.getStatusCode() == HttpStatus.SC_UNAUTHORIZED)
+ return; // do not throw an exception (wrong user id / password given)
throw new HttpException
("Unable to process request", method.getStatusCode());
}
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>