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

My server crashes because of this plugin #20

Closed
rbozan opened this issue Aug 1, 2014 · 6 comments
Closed

My server crashes because of this plugin #20

rbozan opened this issue Aug 1, 2014 · 6 comments

Comments

@rbozan
Copy link

rbozan commented Aug 1, 2014

Well, crashdetect says so.

I'm using the -d3 flag, and my server is mysteriously crashing after several hours. I'm not sure if it's my fault, but crashdetect logs this for me:

[17:39:10] [debug] Server crashed while executing NFS.amx
[17:39:10] [debug] AMX backtrace:
[17:39:10] [debug] #0 native Streamer_CallbackHook () [741d9830] from streamer.DLL
[17:39:10] [debug] #1 000005a8 in public OnPlayerDisconnect (playerid=0, reason=0) at C:\Users\roobi_000\Google Drive\GTA SA\NCRP\pawno\include\streamer.inc:323
[17:39:10] [debug] Native backtrace:
[17:39:11] [debug] #0 7422155f in Load () from C:\Users\root\Desktop\NFS-samp\plugins\crashdetect.DLL
[17:39:11] [debug] #1 74222844 in Load () from C:\Users\root\Desktop\NFS-samp\plugins\crashdetect.DLL
[17:39:11] [debug] #2 7422470e in Load () from C:\Users\root\Desktop\NFS-samp\plugins\crashdetect.DLL
[17:39:11] [debug] #3 75620736 in UnhandledExceptionFilter () from C:\Windows\SYSTEM32\KERNELBASE.dll
[17:39:11] [debug] #4 0049eef6 in ?? () from C:\Users\root\Desktop\NFS-samp\samp-server.exe
[17:39:11] [debug] #5 00498331 in ?? () from C:\Users\root\Desktop\NFS-samp\samp-server.exe
[17:39:11] [debug] #6 757a8543 in BaseThreadInitThunk () from C:\Windows\SYSTEM32\KERNEL32.DLL
[17:39:11] [debug] #7 77ebac69 in RtlInitializeExceptionChain () from C:\Windows\SYSTEM32\ntdll.dll
[17:39:11] [debug] #8 77ebac3c in RtlInitializeExceptionChain () from C:\Windows\SYSTEM32\ntdll.dll

I'm unsure what's happening. I thought it might be my streamer plugin being outdated, so I updated it but this still happens. Then I thought, maybe it's crashdetect bugging out the server.. So I removed that plugin, still same crash.

I'm running on a Windows server.

Anyone knows how to fix this? I'm running the latest streamer plugin and everything works, but after a few hours the server crashes.

@rbozan
Copy link
Author

rbozan commented Aug 1, 2014

It could be related to this:
#13

I'm not sure though, but at OnPlayerDisconnect, it does say playerid 0 (null), and it does have an error at the callback hook.

@samp-incognito
Copy link
Owner

Could be because some other include is hooking OnPlayerDisconnect incorrectly (or there's some problem in your script with that callback), and that error is propagating to the streamer include's callback hook. I'm guessing that crash is happening because a null pointer is being dereferenced due to one or more of the OnPlayerDisconnect parameters being null, for some reason. That's what was #13 was about, anyway (which was due to someone incorrectly invoking Streamer_CallbackHook with sampgdk, so unless you're doing that, the cause of your problem lies elsewhere).

I could see about adding additional checks to the callback hooks so that the server doesn't crash if Streamer_CallbackHook is executed incorrectly, but I think you should see what's going on with your OnPlayerDisconnect code first.

@rbozan
Copy link
Author

rbozan commented Aug 1, 2014

I would like it if you could add these additional checks. I'm currently clueless as I can't see anything wrong with my OnPlayerDisconnect.

I hope you can add those additional checks. I will reread my whole OnPlayerDisconnect code again, but I'm not sure if I can find anything suspicious.

@rbozan
Copy link
Author

rbozan commented Aug 3, 2014

Please tell me when you've added those additional checks. My server gets quite popular but the crashes makes it almost impossible to hit a higher player base.

@samp-incognito
Copy link
Owner

The integrated callback hooks from sampgdk I've just re-added should solve this issue, as long as there aren't other problems associated with them as well. I'll see about releasing a new version for testing soon.

@rbozan
Copy link
Author

rbozan commented Aug 4, 2014

Thanks :)

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

No branches or pull requests

2 participants