chiark
/
gitweb
/
~ian
/
hippotat.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
hippotatd: support --pidfile
[hippotat.git]
/
w3mstracetodump
diff --git
a/w3mstracetodump
b/w3mstracetodump
index bb9305edf061350160c17fc89c22ce7def802f1d..907af4f4f605eeb37450ce291fc8da8047ddc504 100755
(executable)
--- a/
w3mstracetodump
+++ b/
w3mstracetodump
@@
-1,7
+1,12
@@
#!/usr/bin/perl -n
#!/usr/bin/perl -n
-next unless s{^write\(7, "}{};
-next unless m/^POST|GET/..0;
+# strace -s70000 -ot w3m ./form.html
+
+next unless
+ (m/^connect\((\d+),.*AF_INET/ and $fd = $1) ..
+ m/^close\($fd\)/;
+
+next unless s{^write\($fd, "}{};
s{", \d+\)\s+= \d+\n}{};
s{\\r}{\r}g;
s{\\n}{\n}g;
s{", \d+\)\s+= \d+\n}{};
s{\\r}{\r}g;
s{\\n}{\n}g;