http://qs321.pair.com?node_id=1189443


in reply to Odd LWP Problem

I concur with choroba that it's odd. I see no difference under Perl 5.22 ActiveState (or 5.20):
This is perl 5, version 22, subversion 1 (v5.22.1) built for MSWin32-x +86-multi-t hread-64int (with 1 registered patch, see perl -V for more detail) Copyright 1987-2015, Larry Wall Binary build 2201 [299574] provided by ActiveState http://www.ActiveSt +ate.com Built Dec 24 2015 12:36:28
But get an unhandled exception under 64-bit ActiveState 5.22 and 5.24:
This is perl 5, version 22, subversion 1 (v5.22.1) built for MSWin32-x +64-multi-t hread (with 1 registered patch, see perl -V for more detail) Copyright 1987-2015, Larry Wall Binary build 2201 [299574] provided by ActiveState http://www.ActiveSt +ate.com Built Jan 4 2016 12:12:58 ... This is perl 5, version 24, subversion 0 (v5.24.0) built for MSWin32-x +64-multi-t hread (with 1 registered patch, see perl -V for more detail) Copyright 1987-2016, Larry Wall Binary build 2400 [300558] provided by ActiveState http://www.ActiveSt +ate.com Built Jun 9 2016 21:44:59
and it happens for this reduced example:
#! /usr/bin/perl use strict; use warnings; use LWP::Simple; open my $inf, "<", "temp.txt" or die; #This line no longer generates a + warning. while (<$inf>) { #while (<DATA>) { my $html = getprint("https://clio.columbia.edu/catalog?q=How%20to% +20conduct%20your%20own%20survey%20&search_field=title_starts_with&f%5 +B-format%5D%5B%5D=Online&commit=Search") or die; } exit; __DATA__ How to conduct your own survey / Priscilla Salant and Don A. Dillman.
Given that I'm seeing something slightly different, can you verify you still see the issue for this posted code? Otherwise, can you edit your code down at all and still see bad behavior?

#11929 First ask yourself `How would I do this without a computer?' Then have the computer do it the same way.