mirror of
https://git.proxmox.com/git/qemu-server
synced 2025-08-07 08:58:16 +00:00
config properties: refactor skipping internal options to declarative
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
parent
3d0ee5d41c
commit
5a08fb9c8b
@ -2111,9 +2111,16 @@ sub verify_usb_device {
|
|||||||
sub json_config_properties {
|
sub json_config_properties {
|
||||||
my $prop = shift;
|
my $prop = shift;
|
||||||
|
|
||||||
|
my $skip_json_config_opts = {
|
||||||
|
parent => 1,
|
||||||
|
snaptime => 1,
|
||||||
|
vmstate => 1,
|
||||||
|
runningmachine => 1,
|
||||||
|
runningcpu => 1,
|
||||||
|
};
|
||||||
|
|
||||||
foreach my $opt (keys %$confdesc) {
|
foreach my $opt (keys %$confdesc) {
|
||||||
next if $opt eq 'parent' || $opt eq 'snaptime' || $opt eq 'vmstate' ||
|
next if $skip_json_config_opts->{$opt};
|
||||||
$opt eq 'runningmachine' || $opt eq 'runningcpu';
|
|
||||||
$prop->{$opt} = $confdesc->{$opt};
|
$prop->{$opt} = $confdesc->{$opt};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user