Cutted stream

J

Jarek

Hello!

I have a very simple perl script:

<print http headers>

open FILE, "<myfile" or die "Can't open myfile: $!";
while ($line = <FILE>) {
print $line;
}
print "</pre></body></html>\n\n";

which should work as a trivial HTTP server started from inetd.

When I make a telnet to the port where script is waiting, I'm getting
all the "myfile" (so the script is working as expected).
But when I use browser, I'm getting only part of the file.

tcpdump shows that connections is cleared by serwer in the middle of
the file.

The question is: what is wrong ?

JT.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,780
Messages
2,569,611
Members
45,286
Latest member
ChristieSo

Latest Threads

Top