Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Ooops I commited some debug source code in previous

versions. Going back. Sorry.
  • Loading branch information...
commit 300ae26c2d7e60197be45f79bd1a3ab5ef76b796 1 parent 41923e7
stronk7 authored
View
11 backup/backuplib.php
@@ -929,6 +929,7 @@ function backup_zip ($preferences) {
$files = array();
foreach ($filelist as $file) {
//If directory, append "/"
+ //Commented. Not needed wit version 2.0 of pclzip !!
//if (is_dir($basedir."/".$file)) {
// $file = $file."/";
//}
@@ -937,16 +938,16 @@ function backup_zip ($preferences) {
$files[] = $basedir."/".$file;
}
include_once("$CFG->dirroot/lib/pclzip/pclzip.lib.php");
- include_once("$CFG->dirroot/lib/pclzip/pclerror.lib.php");
- include_once("$CFG->dirroot/lib/pclzip/pcltrace.lib.php");
- PclTraceOn(2);
+ //include_once("$CFG->dirroot/lib/pclzip/pclerror.lib.php"); //Debug
+ //include_once("$CFG->dirroot/lib/pclzip/pcltrace.lib.php"); //Debug
+ //PclTraceOn(2); //Debug
$archive = new PclZip("$basedir/$name");
if (($list = $archive->create($files,PCLZIP_OPT_REMOVE_PATH,$basedir)) == 0) {
error($archive->errorInfo(true));
$status = false;
}
- PclTraceDisplay();
- PclTraceOff();
+ //PclTraceDisplay(); //Debug
+ //PclTraceOff(); //Debug
} else { // Use external zip program
//echo "<br>Using external zip"; //Debug
$files = "";
View
6 backup/restore_execute.html
@@ -276,9 +276,9 @@
//Cleanup temps (files and db)
if ($status) {
echo "<li>".get_string("cleaningtempdata");
- //if (!$status = clean_temp_data ($restore)) {
- // notify("Could not clean up temporary data from files and database");
- //}
+ if (!$status = clean_temp_data ($restore)) {
+ notify("Could not clean up temporary data from files and database");
+ }
}
//End the main ul
View
10 backup/restorelib.php
@@ -11,15 +11,15 @@ function restore_unzip ($file) {
if (empty($CFG->unzip)) { // Use built-in php-based unzip function
include_once("$CFG->dirroot/lib/pclzip/pclzip.lib.php");
- include_once("$CFG->dirroot/lib/pclzip/pclerror.lib.php");
- include_once("$CFG->dirroot/lib/pclzip/pcltrace.lib.php");
- PclTraceOn(2);
+ //include_once("$CFG->dirroot/lib/pclzip/pclerror.lib.php"); //Debug
+ //include_once("$CFG->dirroot/lib/pclzip/pcltrace.lib.php"); //Debug
+ //PclTraceOn(2); //Debug
$archive = new PclZip($file);
if (!$list = $archive->extract(dirname($file))) {
$status = false;
}
- PclTraceDisplay();
- PclTraceOff();
+ //PclTraceDisplay(); //Debug
+ //PclTraceOff(); //Debug
} else { // Use external unzip program
$command = "cd ".dirname($file)."; $CFG->unzip -o ".basename($file);
Exec($command);
Please sign in to comment.
Something went wrong with that request. Please try again.