зеркало из https://github.com/mozilla/gecko-dev.git
only pay attention to first x-mozilla-status headers when parsing mail message because spammers have been setting x-mozilla-status, r/sr=mscott 196749
This commit is contained in:
Родитель
4a2446d7ba
Коммит
54008bf351
|
@ -917,12 +917,14 @@ int nsParseMailMessageState::ParseHeaders ()
|
||||||
case 'X':
|
case 'X':
|
||||||
if (X_MOZILLA_STATUS2_LEN == end - buf &&
|
if (X_MOZILLA_STATUS2_LEN == end - buf &&
|
||||||
!nsCRT::strncasecmp(X_MOZILLA_STATUS2, buf, end - buf) &&
|
!nsCRT::strncasecmp(X_MOZILLA_STATUS2, buf, end - buf) &&
|
||||||
!m_IgnoreXMozillaStatus)
|
!m_IgnoreXMozillaStatus && !m_mozstatus2.length)
|
||||||
header = &m_mozstatus2;
|
header = &m_mozstatus2;
|
||||||
else if ( X_MOZILLA_STATUS_LEN == end - buf &&
|
else if ( X_MOZILLA_STATUS_LEN == end - buf &&
|
||||||
!nsCRT::strncasecmp(X_MOZILLA_STATUS, buf, end - buf) && !m_IgnoreXMozillaStatus)
|
!nsCRT::strncasecmp(X_MOZILLA_STATUS, buf, end - buf) && !m_IgnoreXMozillaStatus
|
||||||
|
&& !m_mozstatus.length)
|
||||||
header = &m_mozstatus;
|
header = &m_mozstatus;
|
||||||
else if (!nsCRT::strncasecmp(HEADER_X_MOZILLA_ACCOUNT_KEY, buf, end - buf))
|
else if (!nsCRT::strncasecmp(HEADER_X_MOZILLA_ACCOUNT_KEY, buf, end - buf)
|
||||||
|
&& !m_account_key.length)
|
||||||
header = &m_account_key;
|
header = &m_account_key;
|
||||||
// we could very well care what the priority header was when we
|
// we could very well care what the priority header was when we
|
||||||
// remember its value. If so, need to remember it here. Also,
|
// remember its value. If so, need to remember it here. Also,
|
||||||
|
|
Загрузка…
Ссылка в новой задаче