Debian: Game crashes with code 217 when starting round
Mon, 2016-09-19 13:21
I compiled the latest Hedgewars build (few days ago) and it seems that it's ok, but whenever I try to start a round, engine dies unexpectedly with exit code 217.
Here are last few lines from log:
hwengine allegedly wrote:
Loading /Graphics/Hedgehog/amAirMine.png [flags: 7] ok (128x128)
An unhandled exception occurred at $B769B286 :
EAccessViolation : Access violation
$B769B286Heap dump by heaptrc unit
0 memory blocks allocated : 0/0
0 memory blocks freed : 0/0
0 unfreed memory blocks : 0
True heap size : 0
True free heap : 0
Leaving PAGE_INGAME, entering PAGE_MULTIPLAYER
Object::disconnect: Unexpected null parameter
QCoreApplication::postEvent: Unexpected null receiver
Any ideas what caused this?
I know that the log probably doesn't help. How do I get more useful information?
The next thing in a typical log is loading team flags. Can you post the full log please?
--
Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev
My themes / Theme Editor / Code contributions /
Dank
So... Why are you running Hedgewars as root?
--
Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev
Um, does it matter?
I needed root to download all necessary packages, and... then compiled the game from the same terminal, as root. (I know it's a bad idea)
EDIT:
Running as non-root doesn't help (as expected).
My themes / Theme Editor / Code contributions /
Dank
It's mostly that it doesn't seem very safe/wise. Guess you really trust our code ☺
Also seems like it would needlessly complicate working w/ the build. But eh whatev.
Anyway... Since you're doing your own build. Mind making a debug build? gdb stack trace could be helpful.
sudo sh -c "echo 0 > /proc/sys/kernel/yama/ptrace_scope"
while((1));do gdb -p $(pgrep hwengine);done
launch frontend, start a game, type continue in gdb once it finds the process, wait for it to crash, type bt.
--
Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev
My Linux is on virtual machine and I installed it only because it was needed for C programming at my university. After recent accident, I don't even have important data anymore.
Anyways, I can't run the first command:
(I'm probably doing something wrong)
I guess it's important, because that's what I get:
My themes / Theme Editor / Code contributions /
Dank
The ptrace is because normally gdb can't attach these days without disabling security restrictions. I wonder just how old your VM is.
Huh. Exited normally? Interesting..
But you're on a vm - have you run hedgewars ok on that VM before? Maybe it's just opengl problems (although normally they don't show up at that point in the log)
--
Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev
I'm using newest VirtualBox and my VM was reinstalled few days ago.
I just tried installing normal Hedgewars package with apt-get and I'm able to run the game (but it has some problems with controls).
EDIT:
Nevermind, I compiled 0.9.22 and works as intended. There's a camera problem, but that's probably VM thing.
My themes / Theme Editor / Code contributions /
Dank
'k... so what was the problem in the end?
--
Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev
Eh, I don't know. After I've seen that HW from normal Debian package works, I suspected that it was just broken build. I then tried pulling the newest build, but it didn't even compile.
The 0.9.22 release works perfectly. So it seems like when you download the newest available dev build, you are not guaranteed that it will work or even compile, am I right?
My themes / Theme Editor / Code contributions /
Dank
So... the dev build, sheepluva completely stripped out all SDL 1.2... 0.9.22 was still using SDL 1.2 - probably this is our biggest release blocker at the moment. There's a bug with my XCompose in latest dev, and wouldn't surprise me if there's other issues too. If it turns out these aren't getting fixed, might have to revert those commits...
*looks at sheepluva*
--
Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev
Seems some build-breaking typo slipped into a commit 4 days ago that made it to -dev.
It was fixed now though, please try to rebuild.
EDIT: OH and server dependencies changed too, but just pass -DNOSERVER=1 to cmake and you should be fine.
sheepluva <- me my code stats ->
a Hedgewars Developer
click here to message me
<- where I'm from what I speak ->
It's not that important for me, because I was able to successfully modify the stable release, so seems like I could do something more with it.
Even if I wanted to update, seems like I can't do it right now ;_; I get this error message:
"abort: error: Name or service not known"
It happens even when I remove the trunk and try to clone it again.
EDIT:
Ok, it randomly started to work again, so I re-cloned it and rebuilt and I get the same error code 217 as previously.
Using Hedgewars 0.9.23-r11866 (afa8182003cc)
My themes / Theme Editor / Code contributions /
Dank
As for me the error got fixed, just update sources to the last revision.
XMPP:alzen@jid.pl / GG: 3747253
^
Didn't work. Still stuck at 0.9.22 ¬_¬
UPDATE
It now crashes after this:
My themes / Theme Editor / Code contributions /
Dank
When things like this happen and I really don't know what to to, I usually do this:
hg purge --all
And then I do cmake and build from scatch and also delete my locally installed Hedgewars. This usually helps.
If things are REALLY fucked up and I have no clue whatsoever, I usually reclone the repository and try to build everything from scratch. But I really never need it, actually.
Did you build without the server as nemo suggested?
Here is how I build from scratch:
hg clone ....
cmake .
ccmake . # And I set the configuratino I need
make install
And in the directory in which I installed HW, I just do:
- ./bin/hedgewars
In ccmake, I set:
NOSERVER=1
CMAKE_INSTALL_PREFIX= (some directory on which I have normal write access, e.g. /home/wuzzy/bla )
Note: ccmake is just a “fancy” interface to cmake -D, it doesn't matter which you choose.
Here's how I update:
hg pull --update
OR
hg pull
hg update
The “update” part is IMPORTANT! Don't forget it! Also, before running make install again, don'T forget to also run cmake! Otherwise, a couple of new files might not get installed.
Can you please also check the logs when you run cmake? Maybe an error message sneaks in there which you have overlooked.
Oh, and can you please tell us your operating system?
Also check if you have all the dependencies listed here:
https://hedgewars.org/kb/Dependencies#Core_dependencies
If this still doesn't help, please visit us in our chatroom again.
Hi, I am a Hedgewars developer.
Uh, I completely re-cloned repository numerous times. I think I even built it on fresh OS installation at least once.
This error happens when I run the newest build. When I do hg update 0.9.22, it works alright.
Here's the command I use for cmake:
cmake -DCMAKE_BUILD_TYPE="DEBUG"
-DCMAKE_INSTALL_PREFIX="$HOME/games"
-DDATA_INSTALL_DIR="$HOME/games" -DNOSERVER=1 -DNOPNG=1
-DNOVIDEOREC=1
(it's the same one as on HWKB)
And the log:
Here's log I get for 0.9.22:
It's obviously shorter, but I don't know which parts actually matter >_>
My OS is Debian Wheezy on VirtualBox 5 (although being an VM doesn't really explain why only one version would be broken)
EDIT:
So, the cmake log for 0.9.22 is somehow different now.
Also, any ideas why HW freezes sometimes at freeing resources? And exiting game doesn't always end the process and I have to kill it.
My themes / Theme Editor / Code contributions /
Dank
Okay, so your cmake logs don't look suspicious. At least not to me.
But your crash message of the hwengine is interesting. Normally, it should looks like this (look below Progress.png):
Maybe hwengine has some problems in loading SDL libraries? But I have not really a idea at the moment (I also haven't dug deep yet). Hmm …
I'm not sure if it helps but you could try to update all the required libraries.
You can check here if your libraries are up to date: https://hedgewars.org/kb/Dependencies#Core_dependencies
Oh, please name us all the decendency libraries you have on the system. Hedgewars neatly displays them in the about screen (click on the Hedgewars logo in the main menu).
Hi, I am a Hedgewars developer.
EDIT:
Looking at dependencies, my PhysFS is outdated (I shouldn't be able to run older version too, actually). I'm trying to figure out how to update it.
EDIT2:
I compiled PhysFS from source, but I have to re-link HW to load it from local path ;_;
My themes / Theme Editor / Code contributions /
Dank
I just helped KoBeWi in IRC to debug hwengine. KoBeWi issued this command:
gdb --args ./hwengine (path to demo)
And then just let GDB run and grabbed the backtrace for me. This is the backtrace which I post here for documentation purposes:
(some directories replaced with “*****” to preserve privacy.)
Thanks, KoBeWi, for cooperating so far.
I still need to dig deeper …
Hi, I am a Hedgewars developer.
I fixed it by upgrading to Debian 8 ¯\_(ツ)_/¯
Debian 7 has outdated packages, especially SDL. You'd probably need to compile it from source, so if you are trying the newest HW release on Debian 7, you are gonna have a hard time.
On the other hand, on Debian 8 everything works out-of-the-box, without further configuration. Just copy the commands from HWKB's "BuildingOnLinux" and you are done.
(btw, KDE is kool)
My themes / Theme Editor / Code contributions /
Dank