Could somebody please explain what this line does? $x<<3

2005-03-18 Thread Angerstein
I have a Line of code I just don´t know waht it does. Especialy the underlined section: All used vars are scalars. my $d = (($facility_i<<3)|($priority_i)); -- Its from Net::Syslog syslog.pm line 93. Thanks Bastian -- To unsubscribe, e-mail: [EMAIL PROTECTED] For addi

Re: Could somebody please explain what this line does? $x<<3

2005-03-18 Thread Kalyan
<< is a left shift operator.. Thanks, Kalyan Kumar M - Original Message - From: "Angerstein" <[EMAIL PROTECTED]> To: Sent: Friday, March 18, 2005 2:48 PM Subject: Could somebody please explain what this line does? $x<<3 > > I have a Line of code I just don´t know wah

Re: Could somebody please explain what this line does? $x<<3

2005-03-18 Thread Rathna N
1. first ($facility_i<<3) will be left shifted thrice 2. the above shift result is bit ORed with $priority_i and value is assigned to $d. ex: perl -e '$x=4; $d=(($x<<3)|(5)); print $d;' Prints : 37 Regards, Rathna. On Fri, 18 Mar 2005 10:18:55 +0100, Angerstein <[EMAIL PROTECTED]> wrote:

Re: Calling a perl script within another

2005-03-18 Thread Ramprasad A Padmanabhan
After a small change This works perfectly fine thank you all > { > $scriptname = get_scriptname($recipient) local(@_) = ($arg1,$arg2,$arg3); do($scriptname); > > $output = $global::output; > # This variable is set by the $scriptname > do_something($output); > }

Re: Could somebody please explain what this line does? $x<<3

2005-03-18 Thread John W. Krahn
Angerstein wrote: I have a Line of code I just don´t know waht it does. Especialy the underlined section: All used vars are scalars. my $d = (($facility_i<<3)|($priority_i)); -- Its from Net::Syslog syslog.pm line 93. perldoc perlop [snip] Shift Operators Binary

Re: Determining standard perl modules

2005-03-18 Thread Gavin Henry
> On Thu, 17 Mar 2005 10:48:30 -0500, Chris Charley wrote: >> >> > Dear all, >> > >> > How/where do I find out the standard bundled perl modules >> >> Hello Gavin, >> >> perldoc perlmodlib >> >> and then scroll to Standard Modules >> >> Chris Thanks. >> > > Or on the web, see: "http://search.cpa

script "freeze"

2005-03-18 Thread Chris Knipe
Lo all, I suspect this is Crypt::RandPassword's doing, but if anyone can please help, I'd appreciate it (as always) #!/usr/bin/perl use Crypt::RandPasswd; use Mysql; use Net::SMTP; use Number::Format; use POSIX; use strict; use Sys::Syslog; use warnings; # Stage 1: Rotate Test Passwords. $Date

Re: script "freeze"

2005-03-18 Thread Chris Knipe
Strange... comment out use strict, and everything works Is this a coding error??? I can't see anything in the code that should break things, but I do realise it's perhaps not the best of code... -- Chris. - Original Message - From: "Chris Knipe" <[EMAIL PROTECTED]> To: Sent: Friday,

Re: script "freeze"

2005-03-18 Thread Wiggins d'Anconia
Chris Knipe wrote: Lo all, I suspect this is Crypt::RandPassword's doing, but if anyone can please help, I'd appreciate it (as always) #!/usr/bin/perl use Crypt::RandPasswd; use Mysql; use Net::SMTP; use Number::Format; use POSIX; use strict; use Sys::Syslog; use warnings; # Stage 1: Rotate Tes

Re: script "freeze"

2005-03-18 Thread Chris Knipe
The script never gets to the PRINT statements. I run it, it works. I run it again, it just sits there with a blank. Sometimes, one or more of the print statements will execute, sometimes all of them, sometimes none of them. This code is as simple as can be... Am I doing anything wrong?? You

Re: Calling a perl script within another

2005-03-18 Thread Jay Savage
On Fri, 18 Mar 2005 07:46:48 -0500, zentara <[EMAIL PROTECTED]> wrote: > On Thu, 17 Mar 2005 18:57:47 +0200, [EMAIL PROTECTED] (Offer Kaye) > wrote: > > >On Thu, 17 Mar 2005 11:40:10 -0500, zentara wrote: > > > >> > > >> >The above works fine , but I do not want to fork out a new perl process > >>

Problems using open pragma

2005-03-18 Thread Jan Eden
Hi, I have a bunch of files in the iso-8859-1 text encoding which I want to save (in an edited form) as UTF-8. I use the following line: use open IN => ':encoding(iso-8859-1)', OUT => ':utf8'; and it does not work. This is strange, as I use this pragma all the time, and it always worked. Whe

Re: Problems using open pragma

2005-03-18 Thread Jan Eden
Hi, Jan Eden wrote on 18.03.2005: >Hi, > >I have a bunch of files in the iso-8859-1 text encoding which I want >to save (in an edited form) as UTF-8. > >I use the following line: > >use open IN => ':encoding(iso-8859-1)', OUT => ':utf8'; > >and it does not work. > >This is strange, as I use this