Re: I'm fixing to have to travel away from the computer for a while... [message #13987 is a reply to message #13985] |
Sun, 02 November 2003 20:24 |
Ilia
Messages: 13241 Registered: January 2002
Karma:
|
Senior Member Administrator Core Developer |
|
|
1) In the future please do not paste files into messages, attach them instead it makes my life much easier.
As for the fix try the following, replace this:
<?php unction write_pmsg_body($text) { $fp = fopen($GLOBALS['MSG_STORE_DIR'].'private', 'ab');
if( !($s = ftell($fp)) ) $s = __ffilesize($fp);
fwrite($fp, $text); fflush($fp); $len = (ftell($fp)-$s); fclose($fp);
if( !$s ) chmod($GLOBALS['MSG_STORE_DIR'].'private', 0600);
return array($s,$len); } ?>
with
<?php $fp = fopen($GLOBALS['MSG_STORE_DIR'].'private', 'ab');
fseek($fp, 0, SEEK_END); if (!($s = ftell($fp))) { $s = __ffilesize($fp); }
if (($len = fwrite($fp, $text)) !== strlen($text)) { exit("FATAL ERROR: system has ran out of disk space \n"); } fclose($fp);
return array($s, $len); ?>
However, I'd strongly recommend upgrading your FUDforum version.
FUDforum Core Developer
|
|
|