mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-01-13 03:24:29 +08:00
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>
|
||||
|
||||
* java/io/File.java: Reformated.
|
||||
|
@ -138,13 +138,13 @@ class Connection extends HttpURLConnection
|
||||
PrintWriter out = new PrintWriter(sock.getOutputStream());
|
||||
|
||||
// Send request including any request properties that were set.
|
||||
out.print(getRequestMethod() + " " + url.getFile() + " HTTP/1.0\n");
|
||||
out.print("Host: " + url.getHost() + ":" + port + "\n");
|
||||
out.print(getRequestMethod() + " " + url.getFile() + " HTTP/1.0\r\n");
|
||||
out.print("Host: " + url.getHost() + ":" + port + "\r\n");
|
||||
Enumeration reqKeys = requestProperties.keys();
|
||||
Enumeration reqVals = requestProperties.elements();
|
||||
while (reqKeys.hasMoreElements())
|
||||
out.print(reqKeys.nextElement() + ": " + reqVals.nextElement() + "\n");
|
||||
out.print("\n");
|
||||
out.print(reqKeys.nextElement() + ": " + reqVals.nextElement() + "\r\n");
|
||||
out.print("\r\n");
|
||||
out.flush();
|
||||
getHttpHeaders();
|
||||
connected = true;
|
||||
|
Loading…
Reference in New Issue
Block a user