Hi

On Mon, Mar 03, 2008 at 03:19:35PM +0100, Bram Senders wrote:
> Package: adduser
> Version: 3.106
> Severity: important
> File: /usr/sbin/deluser
> 
> Deluser gives an error and then thinks I want to remove the root user.
> See the following transcript:
> 
> ===
> [EMAIL PROTECTED] ~> sudo deluser --remove-all-files test
> Use of uninitialized value in numeric eq (==) at /usr/sbin/deluser line 228.
> WARNING: You are just about to delete the root account (uid 0)
> Usually this is never required as it may render the whole system unusable
> Press immediately Ctrl+C if you want to abort
> ===
> 
> The referenced line 228 contains the following: "if ($uid == 0) {", so I
> guess $uid does not get set; this might be because the "getpwnam($user)"
> call on line 211 is only done if the "system" config parameter is set.

The correct variable would be "$pw_uid" which is always initialized with
the data of the user to delete (see line 173); the patch will go into next
release. Thanks for reporting.

Jörg

-- 
What did you do to the cat? It looks half-dead. -Schroedinger's wife

Attachment: signature.asc
Description: Digital signature

Reply via email to