1
Window / IsKeyPressed Segfault
« on: November 24, 2011, 08:10:57 pm »
Hello. I am just venturing into using SFML's network layer, but this problem is unrelated. Any call to sf::Keyboard::IsKeyPressed() causes a segfault. This started happening by itself, no code changes between when it was working and when it started segfaulting. I just recently installed SFML2 from github, but it did work with the new build for a while.
SFML2, just built from github
OS X 10.6.8
Below is simpler code that fails for me in the same way.
Any ideas?
Thanks,
- Miles
SFML2, just built from github
OS X 10.6.8
Quote
(gdb) run
[a bunch of the usual "Could not find object file" for seemingly unrelated things]
.++++++................................................................................................ done
DEBUG: a
Reading symbols for shared libraries . done
Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0x0000000081000118
0x00007fff848944b7 in IOHIDDeviceGetValue ()
(gdb) backtrace
#0 0x00007fff848944b7 in IOHIDDeviceGetValue ()
#1 0x00000001000292e6 in sf::priv::HIDInputManager::IsKeyPressed ()
#2 0x0000000100027d7a in sf::priv::InputImpl::IsKeyPressed ()
#3 0x0000000100024589 in sf::Keyboard::IsKeyPressed ()
#4 0x0000000100001719 in main ()
(gdb)
Below is simpler code that fails for me in the same way.
Code: [Select]
#include <iostream>
#include <SFML/System.hpp>
#include <SFML/Window.hpp>
int main (int argc, char **argv) {
std::cout << "DEBUG: a" << "\n";
sf::Keyboard::IsKeyPressed(sf::Keyboard::A);
std::cout << "DEBUG: b" << "\n";
}
Any ideas?
Thanks,
- Miles