fixed divide-by-zero error in server
This commit is contained in:
parent
2aa98fbccc
commit
56000bedaa
1 changed files with 1 additions and 1 deletions
|
@ -599,7 +599,7 @@ bool game::end_turn()
|
|||
|
||||
const size_t nsides = level_.get_children("side").size();
|
||||
|
||||
if((end_turn_%nsides) != 0) {
|
||||
if(nsides == 0 || (end_turn_%nsides) != 0) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue