Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

problem with IO::Handle (IO-1.20) #156

Closed
p5pRT opened this issue Jul 3, 1999 · 1 comment
Closed

problem with IO::Handle (IO-1.20) #156

p5pRT opened this issue Jul 3, 1999 · 1 comment

Comments

@p5pRT
Copy link
Collaborator

@p5pRT p5pRT commented Jul 3, 1999

Migrated from rt.perl.org#961 (status was 'resolved')

Searchable as RT961$

@p5pRT
Copy link
Collaborator Author

@p5pRT p5pRT commented Jul 3, 1999

From nagel@intelenet.net

During some debugging, we found that the method input_line_number
in IO​::Handle was encountering a problem because it was referencing
the bareword STDOUT during execution with 'use strict' in scope.
I made the following change to the method​:

sub input_line_number {
  my $now = select;
  my $keep = $.;
  my $tell = tell qualify($_[0], caller) if ref($_[0]);
  my $prev = $.;
  $. = $_[1] if @​_ > 1;
  { no strict 'refs'; $tell = tell $now };
  $. = $keep;
  $prev;
}

I'm not sure if this is the 'right' fix, but it solves my immediate
problem!

Perl Info


Site configuration information for perl 5.00404:

Configured by nagel at Fri Jul 31 14:35:22 PDT 1998.

Summary of my perl5 (5.0 patchlevel 4 subversion 4) configuration:
  Platform:
    osname=solaris, osvers=2.5.1, archname=sun4-solaris
    uname='sunos boris 5.5.1 generic_103640-18 sun4u sparc sunw,ultra-1 '
    hint=previous, useposix=true, d_sigaction=define
    bincompat3=n useperlio=undef d_sfio=undef
  Compiler:
    cc='gcc', optimize='-O', gccversion=2.7.2
    cppflags='-I/opt/local/include -I/opt/local/include/db'
    ccflags ='-I/opt/local/include -I/opt/local/include/db'
    stdchar='unsigned char', d_stdstdio=define, usevfork=false
    voidflags=15, castflags=0, d_casti32=define, d_castneg=define
    intsize=4, alignbytes=8, usemymalloc=y, prototype=define
  Linker and Libraries:
    ld='gcc', ldflags ='-L/opt/local/lib'
    libpth=/opt/local/lib /lib /usr/lib /usr/ccs/lib
    libs=-lsocket -lnsl -lgdbm -ldb -ldl -lm -lc -lcrypt
    libc=/lib/libc.so, so=so
    useshrplib=false, libperl=libperl.a
  Dynamic Linking:
    dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags=' '
    cccdlflags='-fpic', lddlflags='-G -L/opt/local/lib'

Locally applied patches:
	


@INC for perl 5.00404:
	/home/nagel/lib/perl
	/opt/local/lib/perl5/sun4-solaris/5.00404
	/opt/local/lib/perl5
	/opt/local/lib/perl5/site_perl/sun4-solaris
	/opt/local/lib/perl5/site_perl
	/opt/local/lib/perl5/sun4-solaris
	.


Environment for perl 5.00404:
    HOME=/home/nagel
    LANG (unset)
    LD_LIBRARY_PATH=/usr/openwin/lib:/usr/dt/lib:/usr/local/lib
    LOGDIR (unset)
    PATH=/home/nagel/bin/links:/home/nagel/bin/hosts:/home/nagel/bin/sparc-sun-solaris2.5.1:/home/nagel/bin:/opt/java/bin:/opt/msql2/bin:/bin:/usr/bin:/usr/local/bin:/usr/sbin:/usr/ucb:/usr/local/pbmplus:/usr/local/rcs:/usr/local/mtools:/usr/local/nmh/bin:/sybase/bin:/opt/LYNX271/bin
    PERLLIB=/home/nagel/lib/perl
    PERL_BADLANG (unset)
    SHELL=/bin/tcsh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant
You can’t perform that action at this time.