David
Posts: 18
Nickname: malven
Registered: Jul, 2003
|
|
Re: Java I/O Problem.(Thanks!)
|
Posted: Aug 27, 2003 5:49 AM
|
|
You're getting in trouble because you're trying to read using a BufferedStream and the underlying stream that it is wrapping (in this case, the DateInputStream) at the same time. When you invoke inbr.readLine(), it's likely that the entire contents of this small file are being read into the BufferedReader's cache; so the underlying streams see EOF when you ask *them* for more data.
Generally speaking, when you wrap one stream with another, it's not a good idea to continue performing operations on the underlying stream. This is definitely the case when the outer stream is buffering data.
|
|