forked from github/server
spellbook_clear crash fix
This commit is contained in:
parent
dd2f146e27
commit
282cc129d7
|
@ -230,7 +230,9 @@ void free_equipment(void) {
|
||||||
equipment *eq = *eqp;
|
equipment *eq = *eqp;
|
||||||
*eqp = eq->next;
|
*eqp = eq->next;
|
||||||
free(eq->name);
|
free(eq->name);
|
||||||
|
if (eq->spellbook) {
|
||||||
spellbook_clear(eq->spellbook);
|
spellbook_clear(eq->spellbook);
|
||||||
|
}
|
||||||
// TODO: items, subsets
|
// TODO: items, subsets
|
||||||
free(eq);
|
free(eq);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue