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

Simulator's loading of resources #32

Closed
hmwildermuth opened this issue Mar 27, 2016 · 3 comments
Closed

Simulator's loading of resources #32

hmwildermuth opened this issue Mar 27, 2016 · 3 comments
Labels

Comments

@hmwildermuth
Copy link
Collaborator

==9371== Command: ./tests.o
==9371== 
==9371== Invalid read of size 4
==9371==    at 0x507CBB4: sf::priv::GlxContext::GlxContext(sf::priv::GlxContext*) (in /usr/lib/libsfml-window.so.2.1)
==9371==    by 0x5076B9C: sf::priv::GlContext::globalInit() (in /usr/lib/libsfml-window.so.2.1)
==9371==    by 0x5077482: sf::GlResource::GlResource() (in /usr/lib/libsfml-window.so.2.1)
==9371==    by 0x5079A55: sf::Window::Window() (in /usr/lib/libsfml-window.so.2.1)
==9371==    by 0x4E5C3C5: sf::RenderWindow::RenderWindow() (in /usr/lib/libsfml-graphics.so.2.1)
==9371==    by 0x467A30: Simlink::Simlink() (in /home/travis/build/FidoProject/Fido/tests/tests.o)
==9371==    by 0x45A872: ____C_A_T_C_H____T_E_S_T____8() (in /home/travis/build/FidoProject/Fido/tests/tests.o)
==9371==    by 0x4271CD: Catch::FreeFunctionTestCase::invoke() const (in /home/travis/build/FidoProject/Fido/tests/tests.o)
==9371==    by 0x4132F6: Catch::TestCase::invoke() const (in /home/travis/build/FidoProject/Fido/tests/tests.o)
==9371==    by 0x4261DA: Catch::RunContext::invokeActiveTestCase() (in /home/travis/build/FidoProject/Fido/tests/tests.o)
==9371==    by 0x425E69: Catch::RunContext::runCurrentTest(std::string&, std::string&) (in /home/travis/build/FidoProject/Fido/tests/tests.o)
==9371==    by 0x424810: Catch::RunContext::runTest(Catch::TestCase const&) (in /home/travis/build/FidoProject/Fido/tests/tests.o)
==9371==  Address 0xe0 is not stack'd, malloc'd or (recently) free'd
==9371== 
@truell20 truell20 changed the title Getting segfault on simulator Getting segfault on simulator travis build Mar 27, 2016
@truell20 truell20 added the bug label Mar 27, 2016
@truell20
Copy link
Member

@FlyingGraysons This is because I currently load the background and sansation font files using absolute paths. These will only work on my system. The reason it is like that right now is SFML loads files based on current working directory (the directory of the executable) and so the relative path to background.png varies between the running of tests and the running of the library (since their executables are stored in two different dirs).

The problem is documented here: http://en.sfml-dev.org/forums/index.php?topic=7701.0.

@truell20 truell20 changed the title Getting segfault on simulator travis build Simulator's loading of resources Mar 27, 2016
@hmwildermuth
Copy link
Collaborator Author

well no matter what the script cd's into the tests/ directory so put the path from there

@truell20

@truell20 truell20 mentioned this issue Apr 29, 2016
4 tasks
@truell20
Copy link
Member

fixed in f3813ae

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

No branches or pull requests

2 participants