Ignore:
Timestamp:
Aug 30, 2012, 9:20:50 PM (12 years ago)
Author:
rvelices
Message:

bug 2725: Piwigo isn't compatible with suPHP + better handling of watermark upload errors merge from trunk to branch 2.4

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.4/include/ws_functions.inc.php

    r17668 r17676  
    15081508
    15091509  // create the upload directory tree if not exists
    1510   if (!is_dir($upload_dir)) {
    1511     umask(0000);
    1512     if (!@mkdir($upload_dir, 0777, true))
    1513     {
    1514       return new PwgError(500, 'error during buffer directory creation');
    1515     }
    1516   }
    1517 
    1518   if (!is_writable($upload_dir))
    1519   {
    1520     // last chance to make the directory writable
    1521     @chmod($upload_dir, 0777);
    1522 
    1523     if (!is_writable($upload_dir))
    1524     {
    1525       return new PwgError(500, 'buffer directory has no write access');
    1526     }
    1527   }
    1528 
    1529   secure_directory($upload_dir);
     1510  if (!mkgetdir($upload_dir, MKGETDIR_DEFAULT&~MKGETDIR_DIE_ON_ERROR))
     1511  {
     1512    return new PwgError(500, 'error during buffer directory creation');
     1513  }
    15301514
    15311515  $filename = sprintf(
Note: See TracChangeset for help on using the changeset viewer.