On Wed, 12 Nov 2003, Michiel Blotwijk wrote: > If I delete a user account on SME6 using the below perl code, I get exit > code 256. The same perl code on SME 5.6 returns 0. In both cases the > account seems to be cleanly deleted. What am I doing wrong, or can I > simply ignore the first byte of the exit code?
The "first byte" (if ints were 16bits, in MSB order) of the exit code is the return status of the command (see "perldoc -f system") - in this case, signal-event returned 1. This sequence: > db_delete(\%accounts, $username); > my $rc = system("/sbin/e-smith/signal-event", "user-delete", $username); will eventually cause you problems. You won't be able to tell ahead of time which actions will require some of the properties of the account you are deleting in order to do their job. That will depend on what contribs are installed. That's why we always first change the type to "user-deleted", then run the "user-delete" action, then remove the db entry for the account. One of the actions and/or signal-event itself is returning an exit status. You'll need to work out why. -- Charlie Brady [EMAIL PROTECTED] Mitel Networks Corporation http://www.mitel.com/ Phone: +1 (613) 592 5660 or 592 2122 Fax: +1 (613) 592 1175 A: Because we read from top to bottom, left to right. Q: Why should i start my reply below the quoted text? -- Please report bugs to [EMAIL PROTECTED] Please mail [EMAIL PROTECTED] (only) to discuss security issues Support for registered customers and partners to [EMAIL PROTECTED] To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Searchable archive at http://www.mail-archive.com/devinfo%40lists.e-smith.org