forked from github/server
fix segmentation fault in new assert (units without a faction)
This commit is contained in:
parent
17e86ab6cd
commit
a29e6a7f40
|
@ -1,3 +1,4 @@
|
|||
|
||||
[eressea]
|
||||
base = .
|
||||
report = reports
|
||||
|
@ -6,13 +7,13 @@ lomem = 0
|
|||
debug = 0
|
||||
memcheck = 0
|
||||
locales = de,en
|
||||
;game_id = 0
|
||||
|
||||
[lua]
|
||||
install = ../git
|
||||
paths = ../git/lunit:../git/scripts
|
||||
paths = lunit:scripts
|
||||
maxnmrs = 20
|
||||
rules = e2 ; can use -r to override
|
||||
rules = e2
|
||||
|
||||
[editor]
|
||||
color = 1
|
||||
|
||||
|
|
|
@ -702,7 +702,7 @@ void set_level(unit * u, skill_t sk, int value)
|
|||
{
|
||||
skill *sv = u->skills;
|
||||
|
||||
assert(sk != SK_MAGIC || is_monsters(u->faction) || u->number == 1);
|
||||
assert(sk != SK_MAGIC || !u->faction || is_monsters(u->faction) || u->number == 1);
|
||||
if (!skill_enabled(sk))
|
||||
return;
|
||||
|
||||
|
|
Loading…
Reference in New Issue