Summary: | [regression] HTML viewer complains about "external references to images etc." when there are no images | ||
---|---|---|---|
Product: | [Applications] kmail2 | Reporter: | Thiago Macieira <thiago> |
Component: | message list | Assignee: | kdepim bugs <kdepim-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | montel |
Priority: | NOR | ||
Version: | 5.12.3 | ||
Target Milestone: | --- | ||
Platform: | openSUSE | ||
OS: | Linux | ||
Latest Commit: | https://commits.kde.org/messagelib/b551d400afe823b4357b9e3a0ed7ba233e27a77e | Version Fixed In: | 5.13.1 |
Sentry Crash Report: |
Description
Thiago Macieira
2019-12-16 18:09:52 UTC
I confirm it. I will work on it soon. Git commit 56f1d42f68ed2f597fc599e4952ee81e579cd355 by Laurent Montel. Committed on 17/12/2019 at 06:05. Pushed by mlaurent into branch 'release/19.12'. Fix Bug 415254 - [regression] HTML viewer complains about "external references to images etc." when there are no images FIXED-IN: 5.13.1 M +2 -2 messageviewer/src/messagepartthemes/default/defaultrenderer.cpp https://commits.kde.org/messagelib/56f1d42f68ed2f597fc599e4952ee81e579cd355 (In reply to Laurent Montel from comment #2) > Git commit 56f1d42f68ed2f597fc599e4952ee81e579cd355 by Laurent Montel. > Committed on 17/12/2019 at 06:05. > Pushed by mlaurent into branch 'release/19.12'. > > Fix Bug 415254 - [regression] HTML viewer complains about "external > references to images etc." when there are no images > > FIXED-IN: 5.13.1 > > M +2 -2 > messageviewer/src/messagepartthemes/default/defaultrenderer.cpp > > https://commits.kde.org/messagelib/56f1d42f68ed2f597fc599e4952ee81e579cd355 + if (str.contains(QRegularExpression(QLatin1String("<img.*src=http:/"), QRegularExpression::CaseInsensitiveOption)) + || str.contains(QRegularExpression(QLatin1String("<img.*src=https:/"), QRegularExpression::CaseInsensitiveOption))) { How about <img src="https://...">, with the quotes? The code above this section deals with href=", but not src=. This will also trigger as a false positive in the following HTML: <img src="cid:parn-num">Some text goes here blah blah src=http://example.com Hum... indeed. I will improve check. Git commit e7a170f39c26ee7d4a180724c813e65331727492 by Laurent Montel. Committed on 17/12/2019 at 12:36. Pushed by mlaurent into branch 'master'. Test excludeExtraHeader. Need to improve regexp. M +1 -52 messageviewer/src/messagepartthemes/default/defaultrenderer.cpp M +1 -0 messageviewer/src/utils/autotests/CMakeLists.txt A +6 -0 messageviewer/src/utils/autotests/data/image.txt A +6 -0 messageviewer/src/utils/autotests/data/image2.txt A +5 -0 messageviewer/src/utils/autotests/data/noimage.txt A +3 -0 messageviewer/src/utils/autotests/data/noimage2.txt A +3 -0 messageviewer/src/utils/autotests/data/noimage3.txt M +29 -0 messageviewer/src/utils/autotests/messageviewerutilstest.cpp M +3 -0 messageviewer/src/utils/autotests/messageviewerutilstest.h M +50 -0 messageviewer/src/utils/messageviewerutil.cpp M +1 -0 messageviewer/src/utils/messageviewerutil.h https://commits.kde.org/messagelib/e7a170f39c26ee7d4a180724c813e65331727492 Git commit 34ab26ced039167a87f71a8b0a39630480305d99 by Laurent Montel. Committed on 17/12/2019 at 12:38. Pushed by mlaurent into branch 'release/19.12'. Test excludeExtraHeader. Need to improve regexp. (cherry picked from commit e7a170f39c26ee7d4a180724c813e65331727492) M +1 -52 messageviewer/src/messagepartthemes/default/defaultrenderer.cpp M +1 -0 messageviewer/src/utils/autotests/CMakeLists.txt A +6 -0 messageviewer/src/utils/autotests/data/image.txt A +6 -0 messageviewer/src/utils/autotests/data/image2.txt A +5 -0 messageviewer/src/utils/autotests/data/noimage.txt A +3 -0 messageviewer/src/utils/autotests/data/noimage2.txt A +3 -0 messageviewer/src/utils/autotests/data/noimage3.txt M +29 -0 messageviewer/src/utils/autotests/messageviewerutilstest.cpp M +3 -0 messageviewer/src/utils/autotests/messageviewerutilstest.h M +50 -0 messageviewer/src/utils/messageviewerutil.cpp M +1 -0 messageviewer/src/utils/messageviewerutil.h https://commits.kde.org/messagelib/34ab26ced039167a87f71a8b0a39630480305d99 Git commit b551d400afe823b4357b9e3a0ed7ba233e27a77e by Laurent Montel. Committed on 19/12/2019 at 07:22. Pushed by mlaurent into branch 'release/19.12'. Fix Bug 415254 - [regression] HTML viewer complains about "external references to images etc." when there are no images FIXED-IN: 5.13.1 M +0 -3 messageviewer/src/utils/autotests/messageviewerutilstest.cpp M +23 -4 messageviewer/src/utils/messageviewerutil.cpp https://commits.kde.org/messagelib/b551d400afe823b4357b9e3a0ed7ba233e27a77e |