Path: utzoo!utgpu!news-server.csri.toronto.edu!clyde.concordia.ca!uunet!tut.cis.ohio-state.edu!pt.cs.cmu.edu!andrew.cmu.edu!rm55+ From: rm55+@andrew.cmu.edu (Rudolph T. Maceyko) Newsgroups: comp.lang.perl Subject: PERL mucks with "magic number?" Message-ID: Date: 7 May 90 18:08:01 GMT Organization: Carnegie Mellon, Pittsburgh, PA Lines: 32 Hi. I'm trying to use PERL in a multiple-machine (VAX, rt, sun) environment, same OS, though (Andrew, if you know it). Anyway, because of symlink resolution and kernel limits on #! pathnames, my PERL scripts began with #!/bin/csh -f eval "exec /usr/contributed/bin/perl -S $0 $*" if $running_under_some_shell; Well, after patchlevel 15 was installed, all of my scripts began to hang, without doing anything (i.e., no output). I have nothing to do with installing PERL here, by the way. Anyway, it seems that PERL is looking at the "magic number" when it shouldn't be. Actually, it's not only LOOKING, but EXECUTING the pathname as if it were the KERNEL! #!/bin/csh -fx reports an infinite loop of exec'king. What reasoning was behind this change, or, if it wasn't changed, why isn't this implemented intuitively (kernel looks at magic number, PERL ignores it -- it's a comment)? Anyway, the change occurred after an upgrade from 8 to 15. The "fix" is to remove the #! altogether and let the evel "exec ..." / if $running_under_some_shell; do its trick from the shell. Still PERL shouldn't play with the #! line -- how does it know when to stop? Rudy +---------+ : +-----+ : Rudy Maceyko : : +-+ : : rm55+@andrew.cmu.edu : : : +-+ : rtmst@unix.cis.pitt.edu +-+ +-+-+-+