Leavebug Anti-Crash Hack

[Open Assets] Leavebug Anti-Crash Hack 2.2.9

This content may be freely modified and/or maintained by anyone.

Sparkette

Member
flarn2006 submitted a new resource:

Leavebug Anti-Crash Hack - If it's stupid and it works, it's not stupid.

This is a build of SRB2 version 2.2.9 which incorporates merge request !1594, as well as displaying a message in the console whenever the game would have otherwise crashed. This doesn't solve the underlying problem which causes the bug, but it's been proven to work fine as a "band-aid" patch that will at least prevent it from crashing the game. If you host a server and notice it often crashes right when someone leaves, this...

Read more about this resource...
 
I don't normally push things into releases without visual evidence or testing, but I can't exactly test this on my own, and it's for fixing a bug that I don't know how to intentionally cause. I can't leave my usual sendoff review, and can only push this in good faith that this was tested. If anyone reading this has any issue with this mod, report it here immediately.
 
Hosted a Coop or Die netgame with this today and it went pretty smoothly. I did encounter about two crashes and one of them gave a RPT file. If my memory is correct for this RPT... I think I had maybe 16+ users in that instance and was during Sunshine Uplands 1. I have attached the RPT File of this crash.

Here's a screenshot of the message appearing. A user joined and stayed awhile but then had to leave and upon leaving... the console got spammed with the message that the leavebug crash was averted. This was the only time that this occured during the instance.
srb20098.png

The other crash gave no report file as it was pretty much a hard freeze and required me to close it via task manager. It might've been the addons that I was using, though as it happened when me and some players attacked a boss in Terrace Mountain 3 from Cyberdime.

*Note*
The exe is named 'srb2win.exe' in the zip but I renamed it to 'srb2winleavebugfix.exe' as I didn't want to overwrite the vanilla srb2win.exe.
 

Attachments

  • srb2winleavebugfix.RPT
    3 KB · Views: 239
Last edited:
Hosted a Coop or Die netgame with this today and it went pretty smoothly. I did encounter about two crashes and one of them gave a RPT file. If my memory is correct for this RPT... I think I had maybe 16+ users in that instance and was during Sunshine Uplands 1. I have attached the RPT File of this crash.

Here's a screenshot of the message appearing. A user joined and stayed awhile but then had to leave and upon leaving... the console got spammed with the message that the leavebug crash was averted. This was the only time that this occured during the instance.

The other crash gave no report file as it was pretty much a hard freeze and required me to close it via task manager. It might've been the addons that I was using, though as it happened when me and some players attacked a boss in Terrace Mountain 3 from Cyberdime.

*Note*
The exe is named 'srb2win.exe' in the zip but I renamed it to 'srb2winleavebugfix.exe' as I didn't want to overwrite the vanilla srb2win.exe.
Are you saying you crashed right when it said "crash averted"?
 
The game didn't crash when it said CRASH ADVERTED. That image was taken after relaunching the server.
 
I don't normally push things into releases without visual evidence or testing, but I can't exactly test this on my own, and it's for fixing a bug that I don't know how to intentionally cause. I can't leave my usual sendoff review, and can only push this in good faith that this was tested. If anyone reading this has any issue with this mod, report it here immediately.
Sorry about the late response but I actually was the one testing this fix with Flarn, I can attest to it's effectiveness with that specific crash. It certainly made things easier on me regarding having to constantly restart the server to the degree I had to prior to getting this build.
 
seconding this; I'd like to be able to host servers without them crashing every 15 minutes
thirding this, or alternatively i just really wish this problem was fixed in general since it has PLAGUED the game for the last 2 years now
 
thirding this, or alternatively i just really wish this problem was fixed in general since it has PLAGUED the game for the last 2 years now
Can't tell whether 2.2.9 was always this bad or if 2.2.10 is actually worse for this issue, but fourthing this because a 2.2.10 release would be greatly appreciated since it feels like it occors significantly more often now and even to those who perviously never got it. Maybe it's just bad luck, but, every time it occoured so far, it's crashed the game, which just makes it miserable if not impossible to host. It's strange to me that this isn't even part of the vanilla 2.2.10 since a bandage is better than leaving the cut open.. At least, imo.
 
Can't tell whether 2.2.9 was always this bad or if 2.2.10 is actually worse for this issue, but fourthing this because a 2.2.10 release would be greatly appreciated since it feels like it occors significantly more often now and even to those who perviously never got it. Maybe it's just bad luck, but, every time it occoured so far, it's crashed the game, which just makes it miserable if not impossible to host. It's strange to me that this isn't even part of the vanilla 2.2.10 since a bandage is better than leaving the cut open.. At least, imo.
Fifthing this. My server can't get past Castle Eggman without getting cucked by a leavebug, which is just so infuriating since you never know when it'll happen or who's going to be the one that causes the leavebug! An update for 2.2.10 would do wonders for SRB2's online!
 
Back from the dead, since this is reusable and i talked with flarn.
Yeah here's the 2.2.10 build. I don't think my submission will get to be approved, so i'll leave you guys this.

Post automatically merged:

seconding this; I'd like to be able to host servers without them crashing every 15 minutes
thirding this, or alternatively i just really wish this problem was fixed in general since it has PLAGUED the game for the last 2 years now
Can't tell whether 2.2.9 was always this bad or if 2.2.10 is actually worse for this issue, but fourthing this because a 2.2.10 release would be greatly appreciated since it feels like it occors significantly more often now and even to those who perviously never got it. Maybe it's just bad luck, but, every time it occoured so far, it's crashed the game, which just makes it miserable if not impossible to host. It's strange to me that this isn't even part of the vanilla 2.2.10 since a bandage is better than leaving the cut open.. At least, imo.
Fifthing this. My server can't get past Castle Eggman without getting cucked by a leavebug, which is just so infuriating since you never know when it'll happen or who's going to be the one that causes the leavebug! An update for 2.2.10 would do wonders for SRB2's online!
I think i did it good now, it has the d_clisrv.c file and the debug file, just like the 2.2.9 winrar file, now you can actually use it.
https://www.mediafire.com/file/bicqxdsw8jcbm1u/srb2win-leavebughackfix.zip/file
 
Last edited:
Back from the dead, since this is reusable and i talked with flarn.
Yeah here's the 2.2.10 build. I don't think my submission will get to be approved, so i'll leave you guys this.

Post automatically merged:





I think i did it good now, it has the d_clisrv.c file and the debug file, just like the 2.2.9 winrar file, now you can actually use it.
https://www.mediafire.com/file/bicqxdsw8jcbm1u/srb2win-leavebughackfix.zip/file
I tried the mediafire link myself; nobody was able to join my netgames, but the moment i switched to the vanilla client, someone was able to join
 
I tried the mediafire link myself; nobody was able to join my netgames, but the moment i switched to the vanilla client, someone was able to join
well that's weird. i somehow did everything, i did the exact code as flarn did. i honestly dont know what's happening.
but it's better wait for flarn to do a 2.2.10 version soon. because i had no idea what i was doing the github forking, since this was my first time making a custom build which it makes me sad now.
 
I tried the mediafire link myself; nobody was able to join my netgames, but the moment i switched to the vanilla client, someone was able to join
This could actually be your firewall rather than the client since the exe is differently named to the 2.2.9 one and thus requires to ask the firewall for permission again. Erm, assuming you're on Windows and using Windows defender. The pop up appears once.

Either way, I myself can confirm that this does work and does prevent the server from crashing on chatbug leaving. Personally, the issue quoted above doesn't occur.
 
This could actually be your firewall rather than the client since the exe is differently named to the 2.2.9 one and thus requires to ask the firewall for permission again. Erm, assuming you're on Windows and using Windows defender. The pop up appears once.

Either way, I myself can confirm that this does work and does prevent the server from crashing on chatbug leaving. Personally, the issue quoted above doesn't occur.
allright I tried it again and it seems to work; I guess I just hadn't gotten the firewall prompt the first time i tried it or I hit the wrong button or something
 
yay my custom build works!!!!!!!
I tried using this, and although it does work at first (players were able to join for some time and I was able to see my server in the server browser just like the vanilla build) the server just stops showing up on the master server list after a while of using this, this didn't happen with the vanilla SRB2 build.

EDIT: Works now for some reason, not the best solution but'll do for now until a proper official patch comes out.
 
Last edited:
sigh

here we go again
this time without the d_clisrv.c file because leavebugs were being much more common on my friend's server

allow it to the firewall blah blah, there's still that one side effect of spamming join messages, i don't know how to fix that yet.
 

Who is viewing this thread (Total: 0, Members: 0, Guests: 0)

Back
Top