mirror of
https://git.proxmox.com/git/pve-access-control
synced 2025-08-13 16:53:53 +00:00
pveum: check for $cmd being defined
fixes an 'undefined value' error when no command is specified.
This commit is contained in:
parent
98a34e3ff8
commit
ef740495f0
2
pveum
2
pveum
@ -69,7 +69,7 @@ my $cmddef = {
|
|||||||
|
|
||||||
my $cmd = shift;
|
my $cmd = shift;
|
||||||
|
|
||||||
if ($cmd ne 'verifyapi' && $cmd ne 'printmanpod') {
|
if (defined($cmd) && $cmd ne 'verifyapi' && $cmd ne 'printmanpod') {
|
||||||
die "please run as root\n" if $> != 0;
|
die "please run as root\n" if $> != 0;
|
||||||
|
|
||||||
PVE::INotify::inotify_init();
|
PVE::INotify::inotify_init();
|
||||||
|
Loading…
Reference in New Issue
Block a user