]> git.ipfire.org Git - thirdparty/rspamd.git/commitdiff
[Minor] Fix misprint
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Thu, 8 Jul 2021 18:24:06 +0000 (19:24 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Thu, 8 Jul 2021 18:24:06 +0000 (19:24 +0100)
src/libserver/html/html.cxx
src/libserver/html/html_block.hxx

index 346f87644029f44ece3c859e766b9258760906ca..b8a5e1d32e3d0167229c0d32985b556c37609310 100644 (file)
@@ -2138,6 +2138,9 @@ TEST_CASE("html text extraction")
                        /* Colors */
                        {"goodbye <span style=\"COLOR: rgb(64,64,64)\">cruel</span>"
                         "<span>world</span>", "goodbye cruelworld"},
+                       /* Font-size propagation */
+                       {"<p style=\"font-size: 11pt;line-height:22px\">goodbye <span style=\"font-size:0px\">cruel</span>world</p>",
+                                       "goodbye world\n"},
                        /* Newline before tag -> must be space */
                        {"goodbye <span style=\"COLOR: rgb(64,64,64)\">cruel</span>\n"
                         "<span>world</span>", "goodbye cruel world"},
index 64b53ed7cfaf3c5f99a4b11c51fd7b2b9de1fef6..8416bbc5a5ee3b6c797c760876c1ed1f4ef91725 100644 (file)
@@ -135,7 +135,7 @@ struct html_block {
                 * 5) Parent size is undefined and our size is < 0 - tricky stuff, assume some defaults
                 */
                auto size_prop = [&](auto mask_val, auto &our_val, auto other_val, auto default_val) constexpr -> void {
-                       if (!(mask & mask_val)) {
+                       if ((mask & mask_val)) {
                                /* We have our value */
                                if (our_val < 0) {
                                        if (other.mask & mask_val) {