View Issue Details

IDProjectCategoryView StatusLast Update
0000748Spring engineGeneralpublic2007-12-30 23:06
Reportertvo Assigned ToAuswaschbar  
PrioritynormalSeveritycrashReproducibilityalways
Status resolvedResolutionfixed 
Summary0000748: singlestep immediately crashes the game
DescriptionWhen pressing the o key with default keybinding setup, the game crashes to desktop immediately. By default, o is bound to 'singlestep'.

The game wasn't paused. Singlestep should probably be ignored altogether in this case.
Additional Information(0) _Deque_iterator
    /usr/lib/gcc/i586-mingw32msvc/4.2.1-sjlj/include/c++/bits/stl_deque.h:132

(1) ??
    /var/lib/buildbot/spring_slave/mingw32-4.2/build/rts/Game/GameServer.cpp:803

(2) ??
    /var/lib/buildbot/spring_slave/mingw32-4.2/build/rts/Game/Game.cpp:1129

(3) ??
    /var/lib/buildbot/spring_slave/mingw32-4.2/build/rts/Game/Game.cpp:792

(4) ??
    /var/lib/buildbot/spring_slave/mingw32-4.2/build/rts/System/Main.cpp:1001

(5) Run(int, char**)
    /var/lib/buildbot/spring_slave/mingw32-4.2/build/rts/System/Main.cpp:1115

(6) WinMain@16
    /var/lib/buildbot/spring_slave/mingw32-4.2/build/rts/System/Main.cpp:1178



[22:43:15] <kleaut> else if (cmd == "singlestep") {
[22:43:16] <kleaut> gameServer->CreateNewFrame(false);
[22:43:16] <kleaut> }
TagsNo tags attached.
Checked infolog.txt for Errors

Activities

tvo

2007-12-30 22:54

reporter   ~0001588

This happens only for clients, not the host itself.

Probably the issue is just that there is no check for gameServer != NULL.

Auswaschbar

2007-12-30 22:57

reporter   ~0001589

Should it print a warning ala "Singlestep can only be used when the game is paused" or just silently ignore?

tvo

2007-12-30 22:58

reporter   ~0001590

Additionally, kleaut checked CreateNewFrame: it does not acquire a mutex, so race conditions are probably possible for the host.

tvo

2007-12-30 22:59

reporter   ~0001591

> Should it print a warning ala "Singlestep can only be used when the game is paused" or just silently ignore?
Silently ignore IMHO.

Kloot

2007-12-30 23:03

developer   ~0001592

"Additionally, kleaut checked CreateNewFrame: it does not acquire a mutex, so race conditions are probably possible for the host."

Didn't look closely enough, it does actually (but not right at the top).

Auswaschbar

2007-12-30 23:06

reporter   ~0001593

Singlestep will get ignored when:
- not host
or
- not paused

And there was a mutex_lock in CreateNewFrame, but it locked too late.

Issue History

Date Modified Username Field Change
2007-12-30 22:51 tvo New Issue
2007-12-30 22:52 tvo Severity minor => crash
2007-12-30 22:54 tvo Note Added: 0001588
2007-12-30 22:57 Auswaschbar Note Added: 0001589
2007-12-30 22:58 tvo Note Added: 0001590
2007-12-30 22:59 tvo Note Added: 0001591
2007-12-30 23:03 Kloot Note Added: 0001592
2007-12-30 23:06 Auswaschbar Status new => resolved
2007-12-30 23:06 Auswaschbar Resolution open => fixed
2007-12-30 23:06 Auswaschbar Assigned To => Auswaschbar
2007-12-30 23:06 Auswaschbar Note Added: 0001593