mirror of git://gcc.gnu.org/git/gcc.git
re PR libgcj/12592 (Http requests use \n instead of \r\n)
2003-10-13 Taras Judge <taras.judge@shaw.ca> PR libgcj/12592 * gnu/java/net/protocol/http/Connection.java (connect): Use \r\n, not just \n. From-SVN: r72443
This commit is contained in:
parent
d29b8ad8d8
commit
c1783330fd
|
|
@ -1,3 +1,9 @@
|
||||||
|
2003-10-13 Taras Judge <taras.judge@shaw.ca>
|
||||||
|
|
||||||
|
PR libgcj/12592
|
||||||
|
* gnu/java/net/protocol/http/Connection.java (connect): Use \r\n,
|
||||||
|
not just \n.
|
||||||
|
|
||||||
2003-10-13 Michael Koch <konqueror@gmx.de>
|
2003-10-13 Michael Koch <konqueror@gmx.de>
|
||||||
|
|
||||||
* java/io/File.java: Reformated.
|
* java/io/File.java: Reformated.
|
||||||
|
|
|
||||||
|
|
@ -138,13 +138,13 @@ class Connection extends HttpURLConnection
|
||||||
PrintWriter out = new PrintWriter(sock.getOutputStream());
|
PrintWriter out = new PrintWriter(sock.getOutputStream());
|
||||||
|
|
||||||
// Send request including any request properties that were set.
|
// Send request including any request properties that were set.
|
||||||
out.print(getRequestMethod() + " " + url.getFile() + " HTTP/1.0\n");
|
out.print(getRequestMethod() + " " + url.getFile() + " HTTP/1.0\r\n");
|
||||||
out.print("Host: " + url.getHost() + ":" + port + "\n");
|
out.print("Host: " + url.getHost() + ":" + port + "\r\n");
|
||||||
Enumeration reqKeys = requestProperties.keys();
|
Enumeration reqKeys = requestProperties.keys();
|
||||||
Enumeration reqVals = requestProperties.elements();
|
Enumeration reqVals = requestProperties.elements();
|
||||||
while (reqKeys.hasMoreElements())
|
while (reqKeys.hasMoreElements())
|
||||||
out.print(reqKeys.nextElement() + ": " + reqVals.nextElement() + "\n");
|
out.print(reqKeys.nextElement() + ": " + reqVals.nextElement() + "\r\n");
|
||||||
out.print("\n");
|
out.print("\r\n");
|
||||||
out.flush();
|
out.flush();
|
||||||
getHttpHeaders();
|
getHttpHeaders();
|
||||||
connected = true;
|
connected = true;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue