FIX: $from and $sendto variables are unescaped in the sending error message

This causes addresses like Tom <tom@examp.le> not to be shown in the message.
This commit is contained in:
Florian Mortgat 2019-10-07 17:32:52 +02:00
parent 7aac67f79c
commit 2aee62ea28

View File

@ -460,7 +460,7 @@ if (($action == 'send' || $action == 'relance') && ! $_POST['addfile'] && ! $_PO
$mesg='<div class="error">';
if ($mailfile->error)
{
$mesg.=$langs->trans('ErrorFailedToSendMail',$from,$sendto);
$mesg.=$langs->transnoentities('ErrorFailedToSendMail',dol_escape_htmltag($from),dol_escape_htmltag($sendto));
$mesg.='<br>'.$mailfile->error;
}
else