Ignore:
Timestamp:
Jul 1, 2009, 10:56:41 PM (15 years ago)
Author:
rvelices
Message:
  • remove warn on unset variable
  • insert_user_comment expects now the comment content to be sql safe (works now exactly as update_user_comment)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/ws_functions.inc.php

    r3454 r3488  
    524524
    525525  $comm = array(
    526     'author' => trim( stripslashes($params['author']) ),
    527     'content' => trim( stripslashes($params['content']) ),
     526    'author' => trim($params['author']),
     527    'content' => trim($params['content']),
    528528    'image_id' => $params['image_id'],
    529529   );
     
    886886  // type {thumb, file, high}
    887887  // position
    888  
     888
    889889  if (!is_admin() || is_adviser() )
    890890  {
     
    946946  $pattern = '/'.$original_sum.'-'.$type.'/';
    947947  $chunks = array();
    948  
     948
    949949  if ($handle = opendir($upload_dir))
    950950  {
     
    963963
    964964  ws_logfile('[merge_chunks] memory_get_usage before loading chunks: '.memory_get_usage());
    965  
     965
    966966  foreach ($chunks as $chunk)
    967967  {
    968968    $string = file_get_contents($chunk);
    969    
     969
    970970    ws_logfile('[merge_chunks] memory_get_usage on chunk '.++$i.': '.memory_get_usage());
    971    
     971
    972972    if (!file_put_contents($output_filepath, $string, FILE_APPEND))
    973973    {
    974974      return new PwgError(500, 'error while writting chunks for '.$output_filepath);
    975975    }
    976    
     976
    977977    unlink($chunk);
    978978  }
     
    17841784      );
    17851785  }
    1786  
     1786
    17871787}
    17881788
     
    17901790{
    17911791  return true;
    1792  
     1792
    17931793  file_put_contents(
    17941794    '/tmp/piwigo_ws.log',
Note: See TracChangeset for help on using the changeset viewer.