SV_GetTag crash

Added by palota almost 5 years ago

64-bit etl on Linux crashes with the omnibot mod.
Problem is in function SV_GetTag in file sv_game.c. Why it calls function CL_GetTag ? It does not crash if I remove line "return CL_GetTag(clientNum, tagname, orientation)".
It also works if etl is compiled for debug, because there is condition !defined(LEGACY_DEBUG).
Function CG_GetTag in the omnibot mod is same as in the legacy mod.


Replies (2)

RE: SV_GetTag crash - Added by Radegast almost 5 years ago

I have no idea if the comments surrounding CL_GetTag are still relevant or not, but it looks to me that it can be safely removed. Especially since you say so.

However, if I used the official omnibot_et.x86_64.so from the Assembla repository, it still crashes:

ClientBegin: 4
Userinfo: \name\[BOT]Merki\rate\25000\snaps\20\ip\localhost\cl_guid\OMNIBOT0400000000000000000000000
ClientUserinfoChanged: 4 n\[BOT]Merki\t\2\c\1\lc\1\r\0\m\0000000\s\0000000\dn\\dr\0\w\8\lw\8\sw\7\mu\0\ref\1\u\255
]
Program received signal SIGSEGV, Segmentation fault.
0x00007fffe7e2a79c in Q_stricmpn (s1=0x31 <error: Cannot access memory at address 0x31>, s2=0x7fffe7e5fcaf "func_invisible_user", n=99999) at /home/jsimek/Development/etlegacy/src/qcommon/q_shared.c:1330
1330                    c1 = *s1++;
(gdb) bt
#0  0x00007fffe7e2a79c in Q_stricmpn (s1=0x31 <error: Cannot access memory at address 0x31>, s2=0x7fffe7e5fcaf "func_invisible_user", n=99999) at /home/jsimek/Development/etlegacy/src/qcommon/q_shared.c:1330
#1  0x00007fffe7e2a8d3 in Q_stricmp (s1=0x30 <error: Cannot access memory at address 0x30>, s2=0x7fffe7e5fcaf "func_invisible_user") at /home/jsimek/Development/etlegacy/src/qcommon/q_shared.c:1391
#2  0x00007fffe7e2e20b in _GetEntityClass (_ent=0x7fffe8a89e68 <vote_allow_surrender+232>) at /home/jsimek/Development/etlegacy/src/game/g_etbot_interface.cpp:1683
#3  0x00007fffe7e33f22 in ETInterface::GetEntityClass (this=0x141da20, _ent=...) at /home/jsimek/Development/etlegacy/src/game/g_etbot_interface.cpp:3201
#4  0x00007fffe66498c6 in IGame::UpdateEntity(EntityInstance&) () from legacy/omni-bot/omnibot_et.x86_64.so
#5  0x00007fffe66499bf in IGame::IsEntityValid(GameEntity const&) () from legacy/omni-bot/omnibot_et.x86_64.so
#6  0x00007fffe668b304 in AiState::SensoryMemory::UpdateSight() () from legacy/omni-bot/omnibot_et.x86_64.so
#7  0x00007fffe668b341 in AiState::SensoryMemory::Update(float) () from legacy/omni-bot/omnibot_et.x86_64.so
#8  0x00007fffe66ba860 in StateSimultaneous::UpdateState(float) () from legacy/omni-bot/omnibot_et.x86_64.so
#9  0x00007fffe66ba860 in StateSimultaneous::UpdateState(float) () from legacy/omni-bot/omnibot_et.x86_64.so
#10 0x00007fffe66ba6e2 in StateFirstAvailable::UpdateState(float) () from legacy/omni-bot/omnibot_et.x86_64.so
#11 0x00007fffe6671a0e in Client::Update() () from legacy/omni-bot/omnibot_et.x86_64.so
#12 0x00007fffe66e4ce3 in IGame::UpdateGame() () from legacy/omni-bot/omnibot_et.x86_64.so
#13 0x00007fffe66f3b49 in IGameManager::UpdateGame() () from legacy/omni-bot/omnibot_et.x86_64.so
#14 0x00007fffe7e2f56d in Bot_Interface_Update () at /home/jsimek/Development/etlegacy/src/game/g_etbot_interface.cpp:6447
#15 0x00007fffe7deee73 in vmMain (command=8, arg0=12350, arg1=4294965959, arg2=20268853, arg3=29228784, arg4=0, arg5=214752571104, arg6=140737488347008) at /home/jsimek/Development/etlegacy/src/game/g_main.c:693
#16 0x000000000041cceb in VM_CallFunc (vm=0x1301800 <vmTable>, callnum=8) at /home/jsimek/Development/etlegacy/src/qcommon/vm.c:688
#17 0x00000000004590a4 in SV_Frame (msec=50) at /home/jsimek/Development/etlegacy/src/server/sv_main.c:1597
#18 0x000000000041a7bd in Com_Frame () at /home/jsimek/Development/etlegacy/src/qcommon/common.c:3331
#19 0x000000000046525f in Sys_GameLoop () at /home/jsimek/Development/etlegacy/src/sys/sys_main.c:969
#20 0x0000000000465358 in main (argc=6, argv=0x7fffffffdf88) at /home/jsimek/Development/etlegacy/src/sys/sys_main.c:1066

RE: SV_GetTag crash - Added by Radegast almost 5 years ago

palota, IR4T4 fixed the aforementioned issue. It seems even the upstream omni-bot is now compatible with ET:L. Another milestone reached

(1-2/2)