]> git.proxmox.com Git - pve-ha-manager.git/commitdiff
FenceConfig: early return if file is empty
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Sun, 13 Jan 2019 11:21:26 +0000 (12:21 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Sun, 13 Jan 2019 11:45:45 +0000 (12:45 +0100)
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
src/PVE/HA/FenceConfig.pm

index 3ab00826ff0ea7304c8dbbdf90b141bb233a8ffd..f7ba16d272748688f19f35b6804e03a115a9d691 100644 (file)
@@ -8,7 +8,7 @@ use PVE::Tools;
 sub parse_config {
     my ($fn, $raw) = @_;
 
-    $raw = '' if !$raw;
+    return {} if !$raw;
 
     my $config = {};