From mboxrd@z Thu Jan 1 00:00:00 1970
Return-Path:
Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68])
(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
key-exchange X25519 server-signature RSA-PSS (2048 bits))
(No client certificate requested)
by lists.proxmox.com (Postfix) with ESMTPS id 7D8089014
for ; Tue, 1 Aug 2023 16:46:43 +0200 (CEST)
Received: from firstgate.proxmox.com (localhost [127.0.0.1])
by firstgate.proxmox.com (Proxmox) with ESMTP id 59D60F4DC
for ; Tue, 1 Aug 2023 16:46:13 +0200 (CEST)
Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com
[94.136.29.106])
(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
key-exchange X25519 server-signature RSA-PSS (2048 bits))
(No client certificate requested)
by firstgate.proxmox.com (Proxmox) with ESMTPS
for ; Tue, 1 Aug 2023 16:46:11 +0200 (CEST)
Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1])
by proxmox-new.maurer-it.com (Proxmox) with ESMTP id 4302440975
for ; Tue, 1 Aug 2023 16:46:11 +0200 (CEST)
From: Philipp Hufnagl
To: pve-devel@lists.proxmox.com
Date: Tue, 1 Aug 2023 16:46:00 +0200
Message-Id: <20230801144604.760331-3-p.hufnagl@proxmox.com>
X-Mailer: git-send-email 2.39.2
In-Reply-To: <20230801144604.760331-1-p.hufnagl@proxmox.com>
References: <20230801144604.760331-1-p.hufnagl@proxmox.com>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
X-SPAM-LEVEL: Spam detection results: 0
AWL -0.002 Adjusted score from AWL reputation of From: address
BAYES_00 -1.9 Bayes spam probability is 0 to 1%
DMARC_MISSING 0.1 Missing DMARC policy
KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment
SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record
SPF_PASS -0.001 SPF: sender matches SPF record
T_SCC_BODY_TEXT_LINE -0.01 -
Subject: [pve-devel] [PATCH storage v4 2/2] fix whitespaces
X-BeenThere: pve-devel@lists.proxmox.com
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Proxmox VE development discussion
List-Unsubscribe: ,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
X-List-Received-Date: Tue, 01 Aug 2023 14:46:43 -0000
Signed-off-by: Philipp Hufnagl
---
src/PVE/Storage/Plugin.pm | 22 +++++++++++-----------
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/src/PVE/Storage/Plugin.pm b/src/PVE/Storage/Plugin.pm
index 18cb5d5..1795ae3 100644
--- a/src/PVE/Storage/Plugin.pm
+++ b/src/PVE/Storage/Plugin.pm
@@ -264,7 +264,7 @@ sub verify_server {
my ($server, $noerr) = @_;
if (!(PVE::JSONSchema::pve_verify_ip($server, 1) ||
- PVE::JSONSchema::pve_verify_dns_name($server, 1)))
+ PVE::JSONSchema::pve_verify_dns_name($server, 1)))
{
return undef if $noerr;
die "value does not look like a valid server name or IP address\n";
@@ -472,7 +472,7 @@ sub encode_value {
my ($class, $type, $key, $value) = @_;
if ($key eq 'nodes') {
- return join(',', keys(%$value));
+ return join(',', keys(%$value));
} elsif ($key eq 'content') {
my $res = content_hash_to_string($value) || 'none';
return $res;
@@ -1153,9 +1153,9 @@ sub volume_has_feature {
my $key = undef;
if($snapname){
- $key = 'snap';
+ $key = 'snap';
}else{
- $key = $isBase ? 'base' : 'current';
+ $key = $isBase ? 'base' : 'current';
}
return 1 if defined($features->{$feature}->{$key}->{$format});
@@ -1199,14 +1199,14 @@ sub list_images {
next if !$found;
}
- my $info = {
+ my $info = {
volid => $volid, format => $format,
size => $size, vmid => $owner, used => $used, parent => $parent
};
- $info->{ctime} = $ctime if $ctime;
+ $info->{ctime} = $ctime if $ctime;
- push @$res, $info;
+ push @$res, $info;
}
return $res;
@@ -1580,7 +1580,7 @@ sub volume_export {
run_command(['dd', "if=$file", "bs=4k"], output => '>&'.fileno($fh));
} else {
run_command(['qemu-img', 'convert', '-f', $file_format, '-O', 'raw', $file, '/dev/stdout'],
- output => '>&'.fileno($fh));
+ output => '>&'.fileno($fh));
}
return;
} elsif ($format =~ /^(qcow2|vmdk)\+size$/) {
@@ -1593,7 +1593,7 @@ sub volume_export {
goto unsupported if $file_format ne 'subvol';
write_common_header($fh, $size);
run_command(['tar', @COMMON_TAR_FLAGS, '-cf', '-', '-C', $file, '.'],
- output => '>&'.fileno($fh));
+ output => '>&'.fileno($fh));
return;
}
}
@@ -1662,10 +1662,10 @@ sub volume_import {
or die "internal error: failed to get path to newly allocated volume $volname\n";
if ($data_format eq 'raw' || $data_format eq 'qcow2' || $data_format eq 'vmdk') {
run_command(['dd', "of=$file", 'conv=sparse', 'bs=64k'],
- input => '<&'.fileno($fh));
+ input => '<&'.fileno($fh));
} elsif ($data_format eq 'tar') {
run_command(['tar', @COMMON_TAR_FLAGS, '-C', $file, '-xf', '-'],
- input => '<&'.fileno($fh));
+ input => '<&'.fileno($fh));
} else {
die "volume import format '$format' not available for $class";
}
--
2.39.2