summaryrefslogtreecommitdiff
path: root/sys/src/cmd/mothra
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@felloff.net>2015-08-16 03:19:05 +0200
committercinap_lenrek <cinap_lenrek@felloff.net>2015-08-16 03:19:05 +0200
commitf1efd09bbb88e0c2f103b466aaa731a833932adb (patch)
tree4bbe048437fff3d7c29aa0bf902a1d1aae0f4d4e /sys/src/cmd/mothra
parent344ddf5f55a3bbaec7fdca7aeb72ed684fa43ffe (diff)
mothra: fix crash
Diffstat (limited to 'sys/src/cmd/mothra')
-rw-r--r--sys/src/cmd/mothra/forms.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/src/cmd/mothra/forms.c b/sys/src/cmd/mothra/forms.c
index 39afa62d4..19910d412 100644
--- a/sys/src/cmd/mothra/forms.c
+++ b/sys/src/cmd/mothra/forms.c
@@ -186,7 +186,8 @@ void rdform(Hglob *g){
s=pl_getattr(g->attr, "alt");
if(s==0 || *s == 0) s = f->value;
pl_htmloutput(g, g->nsp, s, f);
- g->state->image[0] = 0;
+ free(g->state->image);
+ g->state->image = 0;
g->state->width=0;
g->state->height=0;
break;