Raised This Month: $51 Target: $400
 12% 

Runtime error 3: stack error


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
PTE
Junior Member
Join Date: Aug 2018
Location: localhost
Old 10-04-2018 , 11:31   Runtime error 3: stack error
Reply With Quote #1

Hello! I'm having error on my server that causes a lot of crushes.
The error is:
Quote:
L 10/03/2018 - 23:22:17: Start of error session.
L 10/03/2018 - 23:22:17: Info (map "jail_especial_v2") (file "addons/amxmodx/logs/error_20181003.log")
L 10/03/2018 - 23:22:17: [AMXX] Displaying debug trace (plugin "jbe_core.amxx", version "1.1.01c")
L 10/03/2018 - 23:22:17: [AMXX] Run time error 3: stack error
L 10/03/2018 - 23:22:17: [AMXX] [0] jbe_core.sma::Show_ChooseTeamMenu (line 2060)
L 10/03/2018 - 23:22:17: [AMXX] [1] jbe_core.sma::Message_ShowMenu (line 5323)
[1] lines with 5323 line:
Code:
public Message_ShowMenu(iMsgId, iMsgDest, iReceiver)
{
	switch(get_msg_arg_int(1))
	{
		case ShowMenu_TeamMenu, ShowMenu_TeamSpectMenu:
		{
			Show_ChooseTeamMenu(iReceiver, 0); // 5323
			return PLUGIN_HANDLED;
		}
		case ShowMenu_ClassMenu, ShowMenu_IgTeamMenu, ShowMenu_IgTeamSpectMenu: return PLUGIN_HANDLED;
	}
	return PLUGIN_CONTINUE;
}
So this func calls the Show_ChooseTeamMenu, so here's the code, btw ye this function has 2060line:
Code:
Show_ChooseTeamMenu(id, iType)
{
	if(jbe_menu_blocked(id)) return PLUGIN_HANDLED; // 2060
	jbe_informer_offset_up(id);
	static szMenu[280], iKeys, iLen;
	iLen = formatex(szMenu, charsmax(szMenu), "\d[lalala] \rВыбор команды^n\d[lalala] \yБаланс: \w3 \dзаключенных, \w1 \dохранник^n^n");
	if(g_iUserTeam[id] != 1)
	{
		iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\d[1] \y~\w %L \r[%d]^n", id, "JBE_MENU_TEAM_PRISONERS", g_iPlayersNum[1]);
		iKeys |= (1<<0);
	}
	else iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\d[1] \y~\w \d%L \r[%d]^n", id, "JBE_MENU_TEAM_PRISONERS", g_iPlayersNum[1]);
	if(!g_BlockMenu && IsNotSetBit(g_iBitUserBlockedGuard, id) && g_iUserTeam[id] != 2 && (floatround(float(g_iPlayersNum[1])/g_iAllCvars[TEAM_BALANCE], floatround_floor)>g_iPlayersNum[2]))
	{
		iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\d[2] \y~\w %L \r[%d]^n^n", id, "JBE_MENU_TEAM_GUARDS", g_iPlayersNum[2]);
		iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\d[5] \y~\w %L^n", id, "JBE_MENU_TEAM_RANDOM");
		iKeys |= (1<<1|1<<4);
	}
	else
	{
		iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\d[2] \y~\w \d%L \r[%d]^n^n", id, "JBE_MENU_TEAM_GUARDS", g_iPlayersNum[2]);
		iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\d[5] \y~\w \d%L^n", id, "JBE_MENU_TEAM_RANDOM");
	}
	if(g_iUserTeam[id] != 3)
	{
		iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\d[6] \y~\w %L^n^n^n^n^n", id, "JBE_MENU_TEAM_SPECTATOR");
		iKeys |= (1<<5);
	}
	else iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\d[6] \y~\w \d%L^n^n^n^n^n", id, "JBE_MENU_TEAM_SPECTATOR");
	if(iType)
	{
		formatex(szMenu[iLen], charsmax(szMenu) - iLen, "^n\d[0] \y~\w %L", id, "JBE_MENU_EXIT");
		iKeys |= (1<<9);
	}
	show_menu(id, iKeys, szMenu, -1, "Show_ChooseTeamMenu");
	return PLUGIN_HANDLED;
}
Actually I've tried to rewrite whole menu and use newmenus.inc, but the error didn't disappear, just showed the same error on some other line in that function(can't remember).

Any suggestions to solve this issue?
PTE is offline
JusTGo
Veteran Member
Join Date: Mar 2013
Old 10-04-2018 , 11:35   Re: Runtime error 3: stack error
Reply With Quote #2

what is your amxx version ?
__________________
JusTGo is offline
PTE
Junior Member
Join Date: Aug 2018
Location: localhost
Old 10-04-2018 , 12:08   Re: Runtime error 3: stack error
Reply With Quote #3

amxx version
AMX Mod X 1.8.3-dev+5154 (http://www.amxmodx.org)
Authors:
David "BAILOPAN" Anderson, Pavol "PM OnoTo" Marko
Felix "SniperBeamer" Geyer, Jonny "Got His Gun" Bergstrom
Lukasz "SidLuke" Wlasinski, Christian "Basic-Master" Hammacher
Borja "faluco" Ferrer, Scott "DS" Ehlert
Compiled: Mar 9 2018 10:40:21
Built from: https://github.com/alliedmodders/amxmodx/commit/2559fcf
Build ID: 5154:2559fcf
Core mode: JIT+ASM32
PTE is offline
JusTGo
Veteran Member
Join Date: Mar 2013
Old 10-04-2018 , 14:41   Re: Runtime error 3: stack error
Reply With Quote #4

try to use the latest version from here https://www.amxmodx.org/downloads-new.php
__________________
JusTGo is offline
PTE
Junior Member
Join Date: Aug 2018
Location: localhost
Old 10-04-2018 , 14:59   Re: Runtime error 3: stack error
Reply With Quote #5

Ok, I'll update my version and compile it with new version yeah? Gonna do it later however.
PTE is offline
PTE
Junior Member
Join Date: Aug 2018
Location: localhost
Old 10-10-2018 , 03:42   Re: Runtime error 3: stack error
Reply With Quote #6

So, I updated, recompiled, server still crashing but without errors in logs...
PTE is offline
JusTGo
Veteran Member
Join Date: Mar 2013
Old 10-10-2018 , 06:18   Re: Runtime error 3: stack error
Reply With Quote #7

try changing this :

PHP Code:
public Message_ShowMenu(iMsgIdiMsgDestiReceiver)
{
    switch(
get_msg_arg_int(1))
    {
        case 
ShowMenu_TeamMenuShowMenu_TeamSpectMenu:
        {
            
Show_ChooseTeamMenu(iReceiver0); // 5323
            
return PLUGIN_HANDLED;
        }
        case 
ShowMenu_ClassMenuShowMenu_IgTeamMenuShowMenu_IgTeamSpectMenu: return PLUGIN_HANDLED;
    }
    return 
PLUGIN_CONTINUE;

to :

PHP Code:
public Message_ShowMenu(iMsgIdiMsgDestiReceiver)
{
    switch(
get_msg_arg_int(1))
    {
        case 
ShowMenu_TeamMenuShowMenu_TeamSpectMenu:
        {
            
set_ent_data(iReceiver"CBasePlayer""m_iMenu"0); // Fix
            
Show_ChooseTeamMenu(iReceiver0); // 5323
            
return PLUGIN_HANDLED;
        }
        case 
ShowMenu_ClassMenuShowMenu_IgTeamMenuShowMenu_IgTeamSpectMenu: return PLUGIN_HANDLED;
    }
    return 
PLUGIN_CONTINUE;

__________________
JusTGo is offline
PTE
Junior Member
Join Date: Aug 2018
Location: localhost
Old 12-03-2018 , 13:59   Re: Runtime error 3: stack error
Reply With Quote #8

PHP Code:
new g_iBitBlockMenu;
public 
jbe_menu_block(pPlayerSetBit(g_iBitBlockMenupPlayer);
public 
jbe_menu_unblock(pPlayerClearBit(g_iBitBlockMenupPlayer);
public 
jbe_menu_blocked(pPlayer) return IsSetBit(g_iBitBlockMenupPlayer); 
I've found following crash log in debug.log:
Quote:
Start Line: ./hlds_linux -debug -game cstrike -master -pingboost 1 -sys_ticrate 500 -secure +ip 193.19.119.166 +port 27032 +map jail_crime -maxplayers 18 +rcon_password *** +sv_password -pidfile hlds.24157.pid
[New LWP 24166]
[New LWP 24767]
[New LWP 31346]
[New LWP 24597]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `./hlds_linux -debug -game cstrike -master -pingboost 1 -sys_ticrate 500 -secure'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0 0xf25ab463 in mysql_next_result () from cstrike/addons/amxmodx/modules/mysql_amxx_i386.so
#0 0xf25ab463 in mysql_next_result () from cstrike/addons/amxmodx/modules/mysql_amxx_i386.so
#1 0xf25a0d33 in SourceMod::MysqlResultSet::~MysqlResultSet() () from cstrike/addons/amxmodx/modules/mysql_amxx_i386.so
#2 0xf2634560 in ?? () from cstrike/addons/amxmodx/modules/mysql_amxx_i386.so
#3 0xffc3fc90 in ?? ()
#4 0xf6f1c90a in Host_Changelevel_f () at ../engine/host_cmd.c:1573
#5 Host_Changelevel_f () at ../engine/host_cmd.c:1521
#6 0xf6f0428d in Cmd_ExecuteString (text=0xffc3fd30 "changelevel jail_adampro_v2", src=<optimized out>) at ../engine/cmd.c:1150
#7 Cbuf_Execute () at ../engine/cmd.c:242
#8 0xf6f1ae70 in _Host_Frame (time=0.00211375812) at ../engine/host.c:1384
#9 0xf6f1b252 in Host_Frame (time=0.00211375812, iState=1, stateInfo=0xffc4021c) at ../engine/host.c:1522
#10 0xf6f3f8dc in CEngine::Frame (this=0xf6fd66a0 <g_Engine>) at ../engine/sys_engine.cpp:245
#11 0xf6f3cc43 in RunFrame (this=<optimized out>) at ../engine/sys_dll2.cpp:1235
#12 CDedicatedServerAPI::RunFrame (this=0xf6fd1d00 <__g_CDedicatedServerAPI_singleton>) at ../engine/sys_dll2.cpp:1226
#13 0x08049c65 in RunServer () at ../dedicated/sys_ded.cpp:766
#14 0x08049472 in main (argc=23, argv=0xffc40454) at ../dedicated/sys_ded.cpp:1146
No symbol table info available.
From To Syms Read Shared Object Library
No linux-gate.so.1
0xf769a914 0xf76e0c78 Yes ./libstdc++.so.6
0xf7641ad0 0xf764296c Yes (*) /lib/i386-linux-gnu/i686/cmov/libdl.so.2
0xf7628840 0xf7634f57 Yes (*) /lib/i386-linux-gnu/i686/cmov/libpthread.so.0
0xf748e420 0xf75be6fe Yes (*) /lib/i386-linux-gnu/i686/cmov/libc.so.6
0xf7435600 0xf7462ed5 Yes (*) /lib/i386-linux-gnu/i686/cmov/libm.so.6
0xf772d860 0xf774580c Yes (*) /lib/ld-linux.so.2
0xf741de04 0xf742d490 Yes ./libgcc_s.so.1
0xf6f01490 0xf6f8524c Yes /home/27032/engine_i486.so
0xf6ea75c0 0xf6eb1d74 Yes (*) ./libsteam_api.so
0xf6e9d9b0 0xf6ea0eaa Yes (*) /lib/i386-linux-gnu/i686/cmov/librt.so.1
0xf6e84a00 0xf6e911b8 Yes /home/27032/filesystem_stdio.so
0xf5f7be80 0xf6a63040 Yes (*) /cs/hlds_6153/steamclient.so
0xf5df6670 0xf5e6c020 Yes (*) /cs/hlds_6153/crashhandler.so
0xf35996a0 0xf35dbf70 Yes (*) /home/27032/./cstrike/addons/metamod/dlls/metamod.so
0xf33b4370 0xf34d8370 Yes /home/27032/cstrike/dlls/cs.so
0xf32fd1c0 0xf3303f30 Yes (*) /home/27032/cstrike/addons/localizebugfix/dlls/localizebugfix.so
0xf3243db0 0xf325fec0 Yes (*) /home/27032/cstrike/addons/whblocker/dlls/whblocker.so
0xf30268c0 0xf31d4571 Yes (*) /home/27032/cstrike/addons/vtc/dlls/vtc.so
0xf2df2890 0xf2e55907 Yes (*) /home/27032/cstrike/addons/amxmodx/dlls/amxmodx.so
0xf2b2c110 0xf2b57650 Yes (*) /home/27032/cstrike/addons/dproto/dlls/dproto.so
0xf259a790 0xf2632fc5 Yes (*) cstrike/addons/amxmodx/modules/mysql_amxx_i386.so
0xf2523b60 0xf256b624 Yes (*) cstrike/addons/amxmodx/modules/hamsandwich_amxx_i386.so
0xf24cd9d0 0xf24f9d6c Yes (*) cstrike/addons/amxmodx/modules/fakemeta_amxx_i386.so
0xf2426d50 0xf2436460 Yes (*) cstrike/addons/amxmodx/modules/cstrike_amxx_i386.so
0xf2408660 0xf240cf94 Yes (*) cstrike/addons/amxmodx/modules/fun_amxx_i386.so
0xf23ed290 0xf23f980c Yes (*) cstrike/addons/amxmodx/modules/engine_amxx_i386.so
0xf20ffad0 0xf21068ab Yes (*) /lib/i386-linux-gnu/i686/cmov/libnss_files.so.2
0xefcffe80 0xf07e7040 Yes (*) ./steamclient.so
0xf0d5e670 0xf0dd4020 Yes (*) ./crashhandler.so
0xf2a795d0 0xf2ac2548 Yes (*) cstrike/addons/amxmodx/modules/regex_amxx_i386.so
0xf2a6af60 0xf2a6c24c Yes (*) cstrike/addons/amxmodx/modules/sockets_amxx_i386.so
(*): Shared library is missing debugging information.
Stack level 0, frame at 0xffc3fb80:
eip = 0xf25ab463 in mysql_next_result; saved eip = 0xf25a0d33
called by frame at 0xffc3fb88
Arglist at 0xffc3fb78, args:
Locals at 0xffc3fb78, Previous frame's sp is 0xffc3fb80
Saved registers:
ebp at 0xffc3fb78, eip at 0xffc3fb7c
End of crash report

Last edited by PTE; 12-03-2018 at 15:23.
PTE is offline
PTE
Junior Member
Join Date: Aug 2018
Location: localhost
Old 10-18-2018 , 08:51   Re: Runtime error 3: stack error
Reply With Quote #9

Im not sure if this helped, players reporting about crashes, I'd like to check it on my own to report for sure, but uptime and default map says enough, still haven't got any error logs, how can I try to fix it or at least get some logs?
PTE is offline
Fuck For Fun
Veteran Member
Join Date: Nov 2013
Old 10-19-2018 , 09:11   Re: Runtime error 3: stack error
Reply With Quote #10

Sometimes the problem comes from a lack of value of a STATIC variable.

What other errors do you get, and I 'd be happy to see func of:

jbe_menu_blocked
Fuck For Fun is offline
Send a message via Skype™ to Fuck For Fun
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 04:06.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode