aspose file tools*
The moose likes Sockets and Internet Protocols and the fly likes downloadWebpage() problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Sockets and Internet Protocols
Bookmark "downloadWebpage() problem" Watch "downloadWebpage() problem" New topic
Author

downloadWebpage() problem

Michael Tan
Greenhorn

Joined: Jul 07, 2009
Posts: 6
im trying to build a custom webpage + RSS reader from scratch.

the method shown below works for the most part. but it will always get this Exception "java.net.SocketException: Unexpected end of file from server" whenever a RSS is from "www.nyaatorrents.org".

but, when i open a RSS using RssReader, it works. so, what am i missing here?

Lester Burnham
Rancher

Joined: Oct 14, 2008
Posts: 1337
It may not explain this problem, but note that the code has a lingering bug waiting to happen: Don't println to a Socket (or, in this case, readLine).
 
 
subject: downloadWebpage() problem
 
Similar Threads
How to start a servlet from a Java Class
Re: Problem about HTTP connection
Error Initializing http tunnel connection.
URL validation
URL connection problem