Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FCNPC crashes when stopping server #55

Closed
Yousha opened this issue Feb 7, 2017 · 7 comments
Closed

FCNPC crashes when stopping server #55

Yousha opened this issue Feb 7, 2017 · 7 comments
Labels

Comments

@Yousha
Copy link
Contributor

Yousha commented Feb 7, 2017

Everything is working fine, but FCNCP plugin crashes when stopping server.

Windows 7 Ultimate 64-bit
Installed Ms VC++ Runtime 2010 to 2015 x64 and x86

Crash log

=========================== FCNPC Exception Handler ============================
Address: 0x7269faa8

Registers:
EAX: 0x0 - EBX: 0x2a9710 - ECX: 0x0 - EDX: 0x4e
ESI: 0xa4 - EDI: 0x6dcf08 - EBP: 0x766534c8 - ESP: 0x18fe00

Stack:
0x0: 0x2a9cfc - 0x4: 0x2800020 - 0x8: 0x726b49ad - 0xC: 0x2a9c50 - 0x10: 0x469dfb - 0x14: 0x2a9710
0x18: 0x766510ff - 0x1C: 0x76651136 - 0x20: 0x0

Information:
System: Windows
SA-MP: 0.3.7 R2-1
FCNPC: 1.6.1

Functions:
FUNC_CPlayerPool__DeletePlayer: 0x466570
FUNC_CPlayer__Kill: 0x484620
FUNC_CPlayer__EnterVehicle: 0x484c70
FUNC_CPlayer__ExitVehicle: 0x484f50
FUNC_CPlayer__SpawnForWorld: 0x486d30
FUNC_GetVehicleModelInfo: 0x488240
FUNC_CConsole__GetIntVariable: 0x48b5b0
FUNC_ClientJoin_RPC: 0x4918f0

Pointers:
VAR_ServerAuthentication: 0x4f5fe8
VAR_NetVersion: 0xfd9

Offsets:
OFFSET_RemoteSystemManager: 0x33c
OFFSET_RemoteSystemSize: 0xcb8
OFFSET_RemoteSystem__ConnectMode: 0xcb0
OFFSET_RemoteSystem__Unknown: 0xcb5
=========================== FCNPC Exception Handler ============================

Server config
plugins crashdetect sscanf streamer mysql FCNPC nativechecker
maxnpc 25 - used 9

server_log.txt

Creating/Spawning NPCs...
[npc:join] npc_0 has joined the server (34:127.0.0.1)
[npc:join] npc_1 has joined the server (33:127.0.0.1)
[npc:join] npc_2 has joined the server (32:127.0.0.1)
[npc:join] npc_3 has joined the server (31:127.0.0.1)
[npc:join] npc_4 has joined the server (30:127.0.0.1)
[npc:join] npc_5 has joined the server (29:127.0.0.1)
[npc:join] npc_6 has joined the server (28:127.0.0.1)
[npc:join] npc_7 has joined the server (27:127.0.0.1)
[npc:join] npc_8 has joined the server (26:127.0.0.1)

@ziggi
Copy link
Owner

ziggi commented Feb 7, 2017

Can you give me your server (in zip) to reproduce this?

@Yousha
Copy link
Contributor Author

Yousha commented Feb 9, 2017

I found the problem! here is:

mysql_connect("x", "x", "x", "x", 3306);

When I remove MySQL connection from my GM, FCNPC doesnt crash after stopping the server.

Also I could remove all of parts from my GM to reproduce that crash and upload it here:
https://ufile.io/e0d192

@ziggi
Copy link
Owner

ziggi commented Feb 9, 2017

Thank you, I will test this later.

@NegativeIQ
Copy link

@Yousha i cant download and take a look at script but did you add mysql_close or what the native function is for that in FS/GM exit?

@Yousha
Copy link
Contributor Author

Yousha commented Feb 10, 2017

@NegativeIQ, no I dont use mysql_close() (its commented always)
And fixed that link...

@NegativeIQ
Copy link

@Yousha i think its mysql that crashes not FCNPC, when server crashes FCNPC detects that and makes crash report. So just add mysql_close() in OnGameModeExit() and if im right you should be fine.

@Yousha
Copy link
Contributor Author

Yousha commented Feb 10, 2017

Yea, right! thanks SOLVED:

[21:58:16] FCNPC Unloaded.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants