Skip to content
Snippets Groups Projects
Commit 73b43dc7 authored by srosse's avatar srosse
Browse files

OO-2119: catch not only error but exception too

parent cf4c11dd
No related branches found
No related tags found
No related merge requests found
...@@ -151,10 +151,10 @@ public class OWASPAntiSamyXSSFilter implements Filter { ...@@ -151,10 +151,10 @@ public class OWASPAntiSamyXSSFilter implements Filter {
log.error("XSS Filter policy error", e); log.error("XSS Filter policy error", e);
printOriginStackTrace(); printOriginStackTrace();
} }
String output = null; String output;
try { try {
output = cr.getCleanHTML(); output = cr.getCleanHTML();
} catch (Error e){ } catch (Exception | Error e){
output = ""; output = "";
log.error("Error getting cleaned HTML from string::" + original, e); log.error("Error getting cleaned HTML from string::" + original, e);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment