mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-23 02:28:44 +02:00
#1165 backup with errors fills up tmp-directories with lots of backup-files
SVN:2.2.0[3869]
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
<?php
|
||||
// Copyright (C) 2010-2012 Combodo SARL
|
||||
// Copyright (C) 2010-2016 Combodo SARL
|
||||
//
|
||||
// This file is part of iTop.
|
||||
//
|
||||
@@ -296,6 +296,13 @@ class DBBackup
|
||||
}
|
||||
if ($iRetCode != 0)
|
||||
{
|
||||
// Cleanup residual output (Happens with Error 2020: Got packet bigger than 'maxallowedpacket' bytes...)
|
||||
if (file_exists($sBackupFileName))
|
||||
{
|
||||
unlink($sBackupFileName);
|
||||
throw new Exception('Effacement du fichier '.$sTmpFileName);
|
||||
}
|
||||
|
||||
$this->LogError("Failed to execute: $sCommandDisplay. The command returned:$iRetCode");
|
||||
foreach($aOutput as $sLine)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user