joystick segs
Zinx Verituse
zinx at epicsol.org
Sat Apr 26 03:45:55 EDT 2003
<intro>
Got ArmyOps installed, and have done same basic testing..
I will be unable to test anything but the very first training
due to driver issues (z-buffer is highly broken in ATI's drivers,
and they don't seem to care. Targets are not all visible.)
For the curious, here's screenshots of z-buffer
issues (ATI driver problem -- it happens in rtcw too):
http://zinx.xmms.org/zinx/misc/tmp/Shot00000.png
http://zinx.xmms.org/zinx/misc/tmp/Shot00001.png
http://zinx.xmms.org/zinx/misc/tmp/Shot00002.png
http://zinx.xmms.org/zinx/misc/tmp/Shot00003.png
</intro>
On to the real issue!
Setting UseJoystick to True in the SDLDrv.SDLClient section
results in a segmentation fault, when a joystick is available:
Backtrace:
[ 1] ./Core.so [0x4087027a]
[ 2] /lib/libpthread.so.0 [0x40c4375a]
[ 3] /lib/libc.so.6 [0x40a289d8]
[ 4] /home/zinx/games/armyops160/System/SDLDrv.so(UpdateInput__12USDLViewportif+0x157) [0x46f1ee4f]
[ 5] ./Engine.so(ResetInput__6UInput+0x2cf) [0x40237ebb]
[ 6] ./Engine.so(Init__6UInputP9UViewport+0x2d) [0x402358fd]
[ 7] ./Engine.so(Init__11UGameEngine+0x599) [0x40202bad]
[ 8] ./armyops-bin [0x804dd9e]
[ 9] ./armyops-bin(main+0x1c24) [0x8050054]
[10] /lib/libc.so.6(__libc_start_main+0xdd) [0x40a17a51]
[11] ./armyops-bin(GetFullName__C7UObjectPw+0x55) [0x804c711]
Signal: SIGSEGV [segmentation fault]
Aborting.
gdb reports something very slightly different:
#0 0x402343c4 in UInput::DirectAxis () from ./Engine.so
#1 0x46eb4e4f in USDLViewport::UpdateInput ()
from /home/zinx/games/armyops160/System/SDLDrv.so
#2 0x40235ebb in UInput::ResetInput () from ./Engine.so
[snip]
(gdb) disassemble $eip $eip+5
Dump of assembler code from 0x402343c4 to 0x402343f6:
0x402343c4 <DirectAxis__6UInput9EInputKeyff+36>: cmpl $0x0,0x4(%eax)
0x402343c8 <DirectAxis__6UInput9EInputKeyff+40>:
je 0x402343d0 <DirectAxis__6UInput9EInputKeyff+48>
(gdb) print /x $eax
$1 = 0xed13c9c
(gdb) print *(int*)($eax+4)
Cannot access memory at address 0xed13ca0
So, I'm guessing uninitialized pointer, or corrupted pointer.
Other points of interest:
It doesn't happen if a joystick wasn't detected anyway.
listing of joystick device nodes:
lr-xr-xr-x 1 root root 9 2003-04-26 01:46 /dev/js0 -> input/js0
cr--r--r-- 1 root root 13, 0 1969-12-31 18:00 /dev/input/js0
crw-rw---- 1 root root 13, 65 1969-12-31 18:00 /dev/input/event1
--
Zinx Verituse
More information about the armyops
mailing list