mirror of
https://github.com/PHPMailer/PHPMailer.git
synced 2024-09-20 10:02:14 +02:00
Ensure that even vars passed by reference are declared, fixes #1968
This commit is contained in:
parent
cc8da73fa2
commit
6ae518109e
@ -3987,6 +3987,7 @@ class PHPMailer
|
||||
foreach ($images[2] as $imgindex => $url) {
|
||||
// Convert data URIs into embedded images
|
||||
//e.g. "data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw=="
|
||||
$match = [];
|
||||
if (preg_match('#^data:(image/(?:jpe?g|gif|png));?(base64)?,(.+)#', $url, $match)) {
|
||||
if (count($match) === 4 && static::ENCODING_BASE64 === $match[2]) {
|
||||
$data = base64_decode($match[3]);
|
||||
|
@ -230,6 +230,8 @@ class POP3
|
||||
}
|
||||
|
||||
// connect to the POP3 server
|
||||
$errno = 0;
|
||||
$errstr = '';
|
||||
$this->pop_conn = fsockopen(
|
||||
$host, // POP3 Host
|
||||
$port, // Port #
|
||||
|
@ -1344,6 +1344,7 @@ class SMTP
|
||||
} else {
|
||||
$this->last_smtp_transaction_id = false;
|
||||
foreach ($this->smtp_transaction_id_patterns as $smtp_transaction_id_pattern) {
|
||||
$matches = [];
|
||||
if (preg_match($smtp_transaction_id_pattern, $reply, $matches)) {
|
||||
$this->last_smtp_transaction_id = trim($matches[1]);
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user