commit 664b938: [Minor] Css: Fix exponent parsing
Vsevolod Stakhov
vsevolod at highsecure.ru
Tue Mar 9 13:00:09 UTC 2021
Author: Vsevolod Stakhov
Date: 2021-03-09 12:56:25 +0000
URL: https://github.com/rspamd/rspamd/commit/664b9385107575c25a14aecc777c1d360d020382 (HEAD -> master)
[Minor] Css: Fix exponent parsing
---
src/libserver/css/css_tokeniser.cxx | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/src/libserver/css/css_tokeniser.cxx b/src/libserver/css/css_tokeniser.cxx
index 1d6e89df7..d836f420a 100644
--- a/src/libserver/css/css_tokeniser.cxx
+++ b/src/libserver/css/css_tokeniser.cxx
@@ -337,6 +337,14 @@ auto css_tokeniser::consume_number() -> struct css_parser_token
if (next_c == '+' || next_c == '-') {
i ++;
}
+ else if (!g_ascii_isdigit(next_c)) {
+ /* Not an exponent */
+ break;
+ }
+ }
+ else {
+ /* Not an exponent */
+ break;
}
}
else {
More information about the Commits
mailing list