2
0
forked from Wavyzz/dolibarr

Fix: Supprime erreurs du a open_basedir

This commit is contained in:
Laurent Destailleur
2007-12-21 00:36:06 +00:00
parent 7e9e15037b
commit 23cd017879

View File

@@ -254,13 +254,15 @@ class CMailFile
*/ */
function send_to_file() function send_to_file()
{ {
$fp = fopen("/tmp/dolibarr_mail","w"); if (@is_writeable("/tmp")) // Avoid fatal error on fopen with open_basedir
fputs($fp, $this->headers); {
fputs($fp, $this->message); $fp = fopen("/tmp/dolibarr_mail","w");
fclose($fp); fputs($fp, $this->headers);
fputs($fp, $this->message);
fclose($fp);
}
} }
/** /**
\brief Creation des headers smtp \brief Creation des headers smtp
*/ */