Fix <style> and <script> erasure.
I didn't take into account that <script […]/> is possible.
This commit is contained in:
parent
262aab6671
commit
a49c500d0f
|
@ -165,7 +165,10 @@ void cleanup_text(string &text)
|
|||
else if (text.substr(pos, 7) == "<style "
|
||||
|| text.substr(pos, 8) == "<script ")
|
||||
{
|
||||
pos = text.find('>', pos) + 1;
|
||||
if (text.find("/>", pos) > endpos)
|
||||
{
|
||||
endpos = text.find('>', endpos) + 1;
|
||||
}
|
||||
}
|
||||
|
||||
DEBUGLOG << "Replacing '" << text.substr(pos, endpos - pos)
|
||||
|
|
Loading…
Reference in New Issue
Block a user