BOFH: Servers Under Siege segfaults after 2min Uzi firing
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
GetDeb Software Portal |
Fix Released
|
Medium
|
Christoph Korn |
Bug Description
While shooting continuously with the Uzi with unlimited ammo (e.g. in Practice mode), the game segfaults suddenly. It takes around 2min until that happens. The reason is that shells and bazooka remainings are remaining actors and MAX_ACTOR (2048) is reached. In that moment spawnactor() from src/actor.c returns NULL but in the ricochet handling in movebullet() the NULL check is missing (line 2553). So it segfaults there.
Affects: all versions so far
Tested with: 0.0.0.0+
Tested on: Ubuntu 14.04 64-bit
With the missing NULL check it doesn't segfault any more but all weapons become ineffective if reaching MAX_ACTOR as there is no freeing of shells or bazooka remainings. So the oldest shells and bazooka remainings have to be freed when reaching that point.
I've developed the fix within a GitHub pull request which got merged but it is in review at the moment. Having more reviewers/testers and putting the final fix into a new Debian package would be great.
Upstream bug: https:/
Upstream pull request: https:/
Taking bofh 0.0.0.0+ 20110602- 1~getdeb1 as starting point.