in reply to strict

First, it is not use strict; which enables these warnings, but rather -w. Anyway, I agree with your theory that it must be the print statements trying to use variables without values.

There are a couple of things you should be aware of in this code. First, you try to print out all the values each time you have read a line from the file. This will of course generate warnings about the use of uninitialized values.

Second, you should probabely use a datastructure to hold your data. As it stands now, you will only get the last record of data, and it will not be correct. It will probabely contain data from earlier records.

A reasonable datastructure to use in this case might possibly be to use a hash of hashes

%data = (user1 => { "User-Service" => "Framed-User", "Framed-Protocoll" => "PPP", # etc... }, user2 => { ... } );
Autark.

Replies are listed 'Best First'.
Re: Re: strict
by toadi (Chaplain) on Nov 22, 2000 at 17:14 UTC
    yes that was the idea ... This maybe solves the problem.
    See I program bit by bit try to do one thing then add a next one if the first one worked.

    I will pump it in a hash, but then still the problem comes up. I THINK :)

    My opinions may have changed,
    but not the fact that I am right

      When you use a hash, you can assign values to keys,
      if there is no value, there is no key, then you can just
      print out all the keys

      And else you just check if the values are defined before
      printing/doing something with them

      GreetZ!,
        ChOas

      I didn't know my example was THAT bad