From d8e365d2ac15346647a765876a789b72be1eb673 Mon Sep 17 00:00:00 2001 From: Fabian Keil Date: Wed, 31 Mar 2021 13:33:17 +0200 Subject: [PATCH] privoxy-log-parser: Highlight 'Socket timeout 3 reached: http://127.0.0.1:20000/no-filter/chunked-content/36' --- tools/privoxy-log-parser.pl | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tools/privoxy-log-parser.pl b/tools/privoxy-log-parser.pl index ce5a83dd..66f6ac4a 100755 --- a/tools/privoxy-log-parser.pl +++ b/tools/privoxy-log-parser.pl @@ -1625,9 +1625,10 @@ sub handle_loglevel_connect($) { $c = highlight_matched_host($c, '(?<=for )[^\s]+'); $c =~ s@(?<=in slot )(\d+)@$h{'Number'}$1$h{'Standard'}@; - } elsif ($c =~ m/^Socket/) { + } elsif ($c =~ m/^Socket \d+ (already|closed)/) { # Socket 16 already forgotten or never remembered. + # Socket 9 closed while waiting for client headers $c =~ s@(?<=Socket )(\d+)@$h{'Number'}$1$h{'Standard'}@; } elsif ($c =~ m/^The connection to/) { @@ -1903,6 +1904,12 @@ sub handle_loglevel_connect($) { # Client socket 7 is no longer usable. The server socket has been closed. $c =~ s@(?<=socket )(\d+)@$h{'Number'}$1$h{'Standard'}@; + } elsif ($c =~ m/^Socket timeout \d+ reached/) { + + # Socket timeout 3 reached: http://127.0.0.1:20000/no-filter/chunked-content/36 + $c =~ s@(?<=timeout )(\d+)@$h{'Number'}$1$h{'Standard'}@; + $c = highlight_matched_url($c, "(?<=reached: ).*") + } elsif ($c =~ m/^Looks like we / or $c =~ m/^Unsetting keep-alive flag/ or $c =~ m/^No connections to wait/ or -- 2.39.2