remgenesis has asked for the wisdom of the Perl Monks concerning the following question:
I use the following lines to request a binary file in a website
my $ua = new LWP::UserAgent("keep_alive"=>3); my $request = new HTTP::Request('GET', $url); my $response = $ua->request($request)
But it seems activeperl treats the file as a text file instead of a binary one. This is not problem when in linux. But in windows, it added a CR (13) byte before each LF(10) byte. So the binary file was corrupted.
How to avoid this in windows?
Formatting fixed by GrandFather
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Problem with requesting a binary file with activeperl in windows
by marto (Cardinal) on Dec 18, 2005 at 21:58 UTC |