mirror of
https://github.com/percona/percona-toolkit.git
synced 2026-02-27 02:00:57 +08:00
Merge lp:~percona-toolkit-dev/percona-toolkit/staging-test-suite-error-fixes r362
This commit is contained in:
@@ -5650,9 +5650,9 @@ sub DESTROY {
|
||||
my $task = $self->{task};
|
||||
if ( ref $task ) {
|
||||
PTDEBUG && _d('Calling cleanup task', $task);
|
||||
open local *STDOUT, ">&=", $self->{stdout_copy}
|
||||
open local(*STDOUT), ">&=", $self->{stdout_copy}
|
||||
if $self->{stdout_copy};
|
||||
open local *STDERR, ">&=", $self->{stderr_copy}
|
||||
open local(*STDERR), ">&=", $self->{stderr_copy}
|
||||
if $self->{stderr_copy};
|
||||
$task->();
|
||||
}
|
||||
|
||||
@@ -57,9 +57,9 @@ sub DESTROY {
|
||||
PTDEBUG && _d('Calling cleanup task', $task);
|
||||
# Temporarily restore STDOUT and STDERR to what they were
|
||||
# when the object was created
|
||||
open local *STDOUT, ">&=", $self->{stdout_copy}
|
||||
open local(*STDOUT), ">&=", $self->{stdout_copy}
|
||||
if $self->{stdout_copy};
|
||||
open local *STDERR, ">&=", $self->{stderr_copy}
|
||||
open local(*STDERR), ">&=", $self->{stderr_copy}
|
||||
if $self->{stderr_copy};
|
||||
$task->();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user