Call by reference error

westwesterson - April 14, 2008 - 17:28
Project:Web File Manager
Version:5.x-2.11
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed
Description

I am receiving this php error as of v. 2.11:
Warning: Call-time pass-by-reference has been deprecated - argument passed by value; If you would like to pass it by reference, modify the declaration of webfm_rename(). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. However, future versions may not support this any longer. in /var/www/html/sites/all/modules/webfm/webfm_file.inc on line 207

line 207 contains

<?php
return(webfm_rename($source, $dest, $uid, &$err_arr));
?>

I believe the error comes from passing a reference in the return statement.
I have provided a patch to fix this error.

AttachmentSize
webfm-call-by-ref.patch619 bytes

#1

robmilne - April 14, 2008 - 19:54
Status:active» fixed

Yikes - I'm made this error before (too much time working in C#). Both of my test sites are too tolerant of this error and it doesn't appear. Fix is committed to DRUPAL-5 head.

#2

Anonymous (not verified) - April 28, 2008 - 20:02
Status:fixed» closed

Automatically closed -- issue fixed for two weeks with no activity.

 
 

Drupal is a registered trademark of Dries Buytaert.