moved common used variables to top of function
This commit is contained in:
parent
0ef2bd2556
commit
16fceba54c
11
syncoid
11
syncoid
|
@ -271,6 +271,8 @@ sub syncdataset {
|
||||||
|
|
||||||
my ($sourcehost, $sourcefs, $targethost, $targetfs, $origin, $skipsnapshot) = @_;
|
my ($sourcehost, $sourcefs, $targethost, $targetfs, $origin, $skipsnapshot) = @_;
|
||||||
|
|
||||||
|
my $stdout, $stderr, $exit;
|
||||||
|
|
||||||
my $sourcefsescaped = escapeshellparam($sourcefs);
|
my $sourcefsescaped = escapeshellparam($sourcefs);
|
||||||
my $targetfsescaped = escapeshellparam($targetfs);
|
my $targetfsescaped = escapeshellparam($targetfs);
|
||||||
|
|
||||||
|
@ -673,9 +675,6 @@ sub syncdataset {
|
||||||
if (!$quiet) { print "Sending incremental $sourcefs#$bookmarkescaped ... $nextsnapshot (~ $disp_pvsize):\n"; }
|
if (!$quiet) { print "Sending incremental $sourcefs#$bookmarkescaped ... $nextsnapshot (~ $disp_pvsize):\n"; }
|
||||||
if ($debug) { print "DEBUG: $synccmd\n"; }
|
if ($debug) { print "DEBUG: $synccmd\n"; }
|
||||||
|
|
||||||
my $stdout;
|
|
||||||
my $stderr;
|
|
||||||
my $exit;
|
|
||||||
($stdout, $stderr, $exit) = tee {
|
($stdout, $stderr, $exit) = tee {
|
||||||
system("$synccmd")
|
system("$synccmd")
|
||||||
};
|
};
|
||||||
|
@ -706,9 +705,6 @@ sub syncdataset {
|
||||||
if (!$quiet) { print "Sending incremental $sourcefs#$bookmarkescaped ... $newsyncsnap (~ $disp_pvsize):\n"; }
|
if (!$quiet) { print "Sending incremental $sourcefs#$bookmarkescaped ... $newsyncsnap (~ $disp_pvsize):\n"; }
|
||||||
if ($debug) { print "DEBUG: $synccmd\n"; }
|
if ($debug) { print "DEBUG: $synccmd\n"; }
|
||||||
|
|
||||||
my $stdout;
|
|
||||||
my $stderr;
|
|
||||||
my $exit;
|
|
||||||
($stdout, $stderr, $exit) = tee {
|
($stdout, $stderr, $exit) = tee {
|
||||||
system("$synccmd")
|
system("$synccmd")
|
||||||
};
|
};
|
||||||
|
@ -750,9 +746,6 @@ sub syncdataset {
|
||||||
if (!$quiet) { print "Sending incremental $sourcefs\@$matchingsnap ... $newsyncsnap (~ $disp_pvsize):\n"; }
|
if (!$quiet) { print "Sending incremental $sourcefs\@$matchingsnap ... $newsyncsnap (~ $disp_pvsize):\n"; }
|
||||||
if ($debug) { print "DEBUG: $synccmd\n"; }
|
if ($debug) { print "DEBUG: $synccmd\n"; }
|
||||||
|
|
||||||
my $stdout;
|
|
||||||
my $stderr;
|
|
||||||
my $exit;
|
|
||||||
($stdout, $stderr, $exit) = tee {
|
($stdout, $stderr, $exit) = tee {
|
||||||
system("$synccmd")
|
system("$synccmd")
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue