in reply to Re: Win32 TCP SYN messages
in thread Win32 TCP SYN messages

my $helpDec = sprintf("%d", 19);
is the same as
my $helpDec = "19";
but you don't even want a string, so you want
my $helpDec = 19;

If you're trying to remove fractional components, use
my $helpDec = int(19);

Replies are listed 'Best First'.
Re^3: Win32 TCP SYN messages
by Mr. Muskrat (Canon) on Jun 21, 2006 at 13:50 UTC
    Yes, I know. I was trying to keep as much of the OP's code as possible.

      Then the comment applies to the OP too.
      $helpDec = sprintf("%d", $ip->{'tos'});
      should be one of:
      $helpDec = $ip->{'tos'};
      $helpDec = 0+$ip->{'tos'};     # Convert string to number
      $helpDec = int($ip->{'tos'});  # Convert string or number to integer