commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject cvs commit: jakarta-commons/latka/src/java/org/apache/commons/latka/http RequestImpl.java
Date Mon, 30 Sep 2002 23:35:54 GMT
dion        2002/09/30 16:35:54

  Modified:    latka/src/java/org/apache/commons/latka/http
                        RequestImpl.java
  Log:
  Fixes for bugs 12727, 12846 as patches provided by Janek Bogucki <yan@studylink.com>
and modified by Daniel Rall
  
  Revision  Changes    Path
  1.33      +7 -10     jakarta-commons/latka/src/java/org/apache/commons/latka/http/RequestImpl.java
  
  Index: RequestImpl.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/latka/src/java/org/apache/commons/latka/http/RequestImpl.java,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -r1.32 -r1.33
  --- RequestImpl.java	25 Sep 2002 23:49:55 -0000	1.32
  +++ RequestImpl.java	30 Sep 2002 23:35:54 -0000	1.33
  @@ -265,7 +265,8 @@
           }
           
           if (_requestBody != null) {
  -            InputStream  is = new ByteArrayInputStream(_requestBody.getBytes("UTF-16"));
  +            InputStream  is = new ByteArrayInputStream(
  +                _requestBody.getBytes("ISO-8859-1"));
               ((PostMethod) _httpMethod).setRequestBody(is);
           } else {
               List parameters = _parameters.getParameters();
  @@ -518,10 +519,6 @@
        * @param version  HTTP version
        */
       public void setVersion(String version) {
  -        if (HTTP_10.equals(version)) {
  -            ((HttpMethodBase) _httpMethod).setHttp11(false);
  -        } else {
  -            ((HttpMethodBase) _httpMethod).setHttp11(true);
  -        }
  +        ((HttpMethodBase) _httpMethod).setHttp11(!HTTP_10.equals(version));
       }
   }
  
  
  

--
To unsubscribe, e-mail:   <mailto:commons-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@jakarta.apache.org>


Mime
View raw message