Changeset 2082

Show
Ignore:
Timestamp:
01/22/08 03:27:22 (11 months ago)
Author:
anarcat
Message:

remove write tests: cp will fail all by itself, no need to test

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • alternc/trunk/bureau/class/m_bro.php

    r2081 r2082  
    422422  function ExtractFile($file, $dest="./") 
    423423  { 
     424    global $err; 
    424425    static $i=0, $ret; 
    425426    $file = $this->convertabsolute($file,0); 
     
    462463  function CopyFile($name, $src, $dest) 
    463464  { 
    464     global $error, $db; 
    465  
    466     $ok = false; 
    467     @mkdir($dest, 0777); 
    468     @chmod($dest, 0777); 
    469     $f = @fopen("$dest/test.php", 'w'); 
    470     if ($f) { 
    471       @fputs($f, '<?php $ok = true; ?>'); 
    472       @fclose($f); 
    473       @chmod("$dest/test.php", 0777); 
    474       include("$dest/test.php"); 
    475     } 
    476     @unlink("$dest/test.php"); 
    477     @rmdir("$dest"); 
    478     if (!$ok) { 
    479       $error = _("No write permissions in the destination directory"); 
    480       return false; 
    481     } 
     465    global $err; 
    482466 
    483467    /*