forked from github/server
null-pointer crash
This commit is contained in:
parent
35b8a137ab
commit
c087ca8b98
|
@ -3616,7 +3616,7 @@ battle_stats(FILE * F, battle * b)
|
||||||
slist = &(*slist)->next;
|
slist = &(*slist)->next;
|
||||||
}
|
}
|
||||||
stat = *slist;
|
stat = *slist;
|
||||||
if (stat->wp!=wp || stat->level!=level) {
|
if (stat==NULL || stat->wp!=wp || stat->level!=level) {
|
||||||
stat = calloc(1, sizeof(stat_info));
|
stat = calloc(1, sizeof(stat_info));
|
||||||
stat->wp = wp;
|
stat->wp = wp;
|
||||||
stat->level = level;
|
stat->level = level;
|
||||||
|
|
Loading…
Reference in New Issue