summaryrefslogtreecommitdiff
path: root/sys/src/cmd/mothra/forms.c
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@gmx.de>2013-08-09 18:23:08 +0200
committercinap_lenrek <cinap_lenrek@gmx.de>2013-08-09 18:23:08 +0200
commite71ff9dc18c0e4d0cd63f0c168e64205af4ccb5a (patch)
treefe8bd54c191959f7a32e0d54a6eefa5413190c18 /sys/src/cmd/mothra/forms.c
parent4c272d44c50c4ed947b93f66e2684747c72ddec4 (diff)
mothra: log post data with debug flag, increase max token length from 1K to 4K
Diffstat (limited to 'sys/src/cmd/mothra/forms.c')
-rw-r--r--sys/src/cmd/mothra/forms.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/sys/src/cmd/mothra/forms.c b/sys/src/cmd/mothra/forms.c
index 0d9054b81..321751214 100644
--- a/sys/src/cmd/mothra/forms.c
+++ b/sys/src/cmd/mothra/forms.c
@@ -687,12 +687,19 @@ void h_submitinput(Panel *p, int){
if(debug)fprint(2, "GET %s\n", buf);
geturl(buf, -1, 0, 0);
} else {
+ if(debug){
+ fprint(2, "POST %s ->\n", form->action);
+ if(form->ctype)
+ mencodeform(form, 2);
+ else
+ uencodeform(form, 2);
+ fprint(2, "\n");
+ }
/* only set for multipart/form-data */
if(form->ctype)
mencodeform(form, fd);
else
uencodeform(form, fd);
- if(debug)fprint(2, "POST %s\n", form->action);
geturl(form->action, fd, 0, 0);
}
}