From: Nicolas Boisselier Date: Tue, 1 Mar 2016 01:45:34 +0000 (+0000) Subject: parse_debug X-Git-Url: https://git.nbdom.net/?a=commitdiff_plain;h=81caff44b0fcb72f063e412a87fa3a41a990ee8b;p=nb.git parse_debug --- diff --git a/bin/dbq b/bin/dbq index 01e0ebf4..7d3dc121 100755 --- a/bin/dbq +++ b/bin/dbq @@ -163,9 +163,9 @@ sub parse_debug { while (<>) { if (/DEBUG: /) { print STDERR $_ } - elsif ( /^(<\w+>)?(Parse error|Warning)/) { print STDERR html2txt($_) } - elsif ( /^
/) { print STDERR html_unescape($_) }
+    elsif ( /^
/) { print STDERR uc($1).': '.html2txt($_) }
     elsif ( /^(<\w+>)?Fatal error/ .. /^\s+thrown in/) { print STDERR html2txt($_) }
+    elsif ( /^(<\s*\w+\s*\/?>)?(Parse error|Fatal error|Warning|Notice|$)/) { print STDERR $_ if ($_=html2txt($_)) and $_ !~ /^\s*$/ }
     else { print $_ }
 
   }