diff --git a/Archive/Tar.php b/Archive/Tar.php index 76771d5..8a2d2db 100644 --- a/Archive/Tar.php +++ b/Archive/Tar.php @@ -257,7 +257,7 @@ public function __destruct() { $this->_close(); // ----- Look for a local copy to delete - if ($this->_temp_tarname != '') { + if ($this->_temp_tarname != '' && (bool) preg_match('/^tar[[:alnum:]]*\.tmp$/', $this->_temp_tarname)) { @unlink($this->_temp_tarname); } }