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

x64 build throws malloc errors #19

Open
WillBrindle opened this issue May 12, 2017 · 1 comment
Open

x64 build throws malloc errors #19

WillBrindle opened this issue May 12, 2017 · 1 comment

Comments

@WillBrindle
Copy link

WillBrindle commented May 12, 2017

This wouldn't run correctly for me on OS X 64-bit without the 32-bit compiler flag (-m32). I believe it comes down to line 397 in demofilebitbuf.cpp. Size of 32 is hard coded for some things but we convert to an unsigned long and move pOut by that much, which when built for 64-bit is 64 bits, and therefore write to more memory than we assigned. I believe just using an int in its place should work and appears to work.

Is this only designed for 32-bit architecture? Are other things likely to go wrong with this fix? I have briefly tested out putting game events and it appeared to work as expected.

@bugdone
Copy link

bugdone commented May 12, 2017

Hi Will,

this commit abenea/demoinfogo-linux@da17ab2 might help

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