I think getpwent expects no parameter. It's unfortunate that it (or Perl) doesn't say so...
Changing your code to use getpwnam instead works for me:
my ( $uid ) = getpwnam($account);
In reply to Re^3: use getpwent to find users and delete them
by Corion
in thread use getpwent to find users and delete them
by garcimo
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |