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

DHooks (Dynamic Hooks - Dev Preview)


Post New Thread Reply   
 
Thread Tools Display Modes
Mainstaff
AlliedModders Donor
Join Date: May 2011
Old 05-16-2014 , 13:29   Re: DHooks (Dynamic Hooks - Dev Preview)
Reply With Quote #181

Quote:
Originally Posted by Rd1981 View Post
Server freezes up with this installed after 5/15/14 update this needs updated now.
Quote:
Originally Posted by Windroid View Post
Server crash with this extension after today's update!
I can't confirm this on Linux Debian 64bit. Maybe only Windows is affected?
Mainstaff is offline
Dr!fter
The Salt Boss
Join Date: Mar 2007
Old 05-17-2014 , 00:23   Re: DHooks (Dynamic Hooks - Dev Preview)
Reply With Quote #182

Works fine after the update, make sure to update all sourcemod gamedata
Dr!fter is offline
Rd1981
Senior Member
Join Date: Apr 2011
Old 05-17-2014 , 03:14   Re: DHooks (Dynamic Hooks - Dev Preview)
Reply With Quote #183

yea windows the dhooks gamedata needs an update for windows I think linux servers arent affected.
Rd1981 is offline
Dr!fter
The Salt Boss
Join Date: Mar 2007
Old 05-17-2014 , 10:02   Re: DHooks (Dynamic Hooks - Dev Preview)
Reply With Quote #184

DHooks doesnt use any gamedata, and plugin gamedata included shouldn't be considered updated. But ill try consider updating the plugin gamedata
Dr!fter is offline
Honorz
Junior Member
Join Date: Sep 2013
Old 05-18-2014 , 12:28   Re: DHooks (Dynamic Hooks - Dev Preview)
Reply With Quote #185

Yes, server freezes after the steam update. I've isolated the issue and discovered this extension is the cause. Please fix.

Thank you.

Honorz
Honorz is offline
Powerlord
AlliedModders Donor
Join Date: Jun 2008
Location: Seduce Me!
Old 05-22-2014 , 19:08   Re: DHooks (Dynamic Hooks - Dev Preview)
Reply With Quote #186

OK, so I started using this to test a Gamerules hook in TF2 PropHunt... and as soon as I did, my Linux test server started segfaulting on shutdown.

Since I changed nothing else, I have to assume it's this extension that's segfaulting.

I'm not manually unhooking the gamerules hook when the server shuts down/plugin unloads, though... is this a known issue?

Edit: ...and since there's no way to manually unhook a gamerules hook...
__________________
Not currently working on SourceMod plugin development.

Last edited by Powerlord; 05-22-2014 at 19:23.
Powerlord is offline
Dr!fter
The Salt Boss
Join Date: Mar 2007
Old 05-22-2014 , 20:20   Re: DHooks (Dynamic Hooks - Dev Preview)
Reply With Quote #187

Quote:
Originally Posted by Powerlord View Post
OK, so I started using this to test a Gamerules hook in TF2 PropHunt... and as soon as I did, my Linux test server started segfaulting on shutdown.

Since I changed nothing else, I have to assume it's this extension that's segfaulting.

I'm not manually unhooking the gamerules hook when the server shuts down/plugin unloads, though... is this a known issue?

Edit: ...and since there's no way to manually unhook a gamerules hook...
Its known about segfaulting on shutdown I haven't had time to look, and isnt that important its shutdown.

And yes you can unhook a gamerules hook manually.
Dr!fter is offline
Powerlord
AlliedModders Donor
Join Date: Jun 2008
Location: Seduce Me!
Old 05-22-2014 , 21:00   Re: DHooks (Dynamic Hooks - Dev Preview)
Reply With Quote #188

Quote:
Originally Posted by Dr!fter View Post
Its known about segfaulting on shutdown I haven't had time to look, and isnt that important its shutdown.
It still bugs me. I may look into this later myself.

Quote:
Originally Posted by Dr!fter View Post
And yes you can unhook a gamerules hook manually.
With DHookRemoveHookID I assume?
__________________
Not currently working on SourceMod plugin development.
Powerlord is offline
Dr!fter
The Salt Boss
Join Date: Mar 2007
Old 05-22-2014 , 21:41   Re: DHooks (Dynamic Hooks - Dev Preview)
Reply With Quote #189

Quote:
Originally Posted by Powerlord View Post
With DHookRemoveHookID I assume?
correct
Dr!fter is offline
Powerlord
AlliedModders Donor
Join Date: Jun 2008
Location: Seduce Me!
Old 05-23-2014 , 13:32   Re: DHooks (Dynamic Hooks - Dev Preview)
Reply With Quote #190

I've been looking over the code and making a few changes here and there to try to figure out where the mysterious shutdown crash is coming from.

The most useful thing I found so far was with a core dump and backtrace with a debug compile of the extension. Here's what I'm getting:
Code:
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `./srcds_linux -game tf +hostname "Source Dedicated Server" +map ph_lumberyard_a'.
Program terminated with signal 11, Segmentation fault.
#0  0xe7824961 in Dynamic::SDK_OnUnload (this=0xe795a200) at extension.cpp:96
96                      g_pSDKHooks->RemoveEntityListener(g_pEntityListener);
(gdb) bt
#0  0xe7824961 in Dynamic::SDK_OnUnload (this=0xe795a200) at extension.cpp:96
#1  0xe782390f in SDKExtension::OnExtensionUnload (this=0xe795a204)
    at sdk/smsdk_ext.cpp:230
#2  0xe8af5729 in CExtensionManager::UnloadExtension(SourceMod::IExtension*) ()
   from /home/tf2/tf2/tf/addons/sourcemod/bin/sourcemod.2.tf2.so
#3  0x00000000 in ?? ()
So... the crash is when RemoveEntityListener is being called.

A few notable things about that line:
  1. g_pEntityListener is checked for NULL pointers on the previous line.
  2. g_pEntityListener is only deleted *after* that line, so shouldn't ever be an invalid pointer.
  3. SDKHooks is registered as a dependency of DHooks, so SDKHooks should still be loaded when DHooks is unloading.
So, what's happening here? From the looks of it, it appears that the dependency is being outright ignored and SDKHooks is being unloaded first.


What's more, you can confirm that this is what's happening by manually unloading the DHooks extension... which results in no crash from SDKHooks (although it still crashes due to issues with the HandleSystem, which I'll look into more in a bit).
__________________
Not currently working on SourceMod plugin development.

Last edited by Powerlord; 05-23-2014 at 13:33.
Powerlord is offline
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 05:13.


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