fix null dereference crash in mothra
This commit is contained in:
parent
62b3eea271
commit
cafcffb1dc
|
@ -1016,11 +1016,13 @@ mothon(Www *w, int on)
|
||||||
plrtstr(&t->next, 0, 0, t->font, strdup("->"), PL_HOT, ap);
|
plrtstr(&t->next, 0, 0, t->font, strdup("->"), PL_HOT, ap);
|
||||||
t->next->next = x;
|
t->next->next = x;
|
||||||
} else {
|
} else {
|
||||||
|
if(x) {
|
||||||
t->next = x->next;
|
t->next = x->next;
|
||||||
x->next = nil;
|
x->next = nil;
|
||||||
freetext(x);
|
freetext(x);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
updtext(w);
|
updtext(w);
|
||||||
donecurs();
|
donecurs();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue