121
Audio / Very simple sf::Music test crashes
« on: January 04, 2015, 09:00:22 pm »
On OS X 10.10, with both SFML 2.2 and Git head, running the following piece of code causes a Bus error:
The file "test.wav" does not exists, so failure is ok but it should not crash. LLDB backtrace is as follow:
int main()
{
sf::Music music;
if (! music.openFromFile("test.wav"))
return 1;
return 0;
}
{
sf::Music music;
if (! music.openFromFile("test.wav"))
return 1;
return 0;
}
The file "test.wav" does not exists, so failure is ok but it should not crash. LLDB backtrace is as follow:
Code: [Select]
* thread #1: tid = 0x1096d8, 0x00007fff951b3fcf libsystem_platform.dylib`OSSpinLockLock + 7, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=2, address=0x100000f74)
* frame #0: 0x00007fff951b3fcf libsystem_platform.dylib`OSSpinLockLock + 7
frame #1: 0x00007fff8b70477d libsystem_pthread.dylib`pthread_mutex_destroy + 25
frame #2: 0x000000010001a497 sfml-system`sf::Mutex::~Mutex() + 23
frame #3: 0x0000000100006b31 sfml-audio`sf::Music::~Music() + 65
frame #4: 0x0000000100000dfb a.out`main + 347
frame #5: 0x00007fff8da4c5c9 libdyld.dylib`start + 1
frame #6: 0x00007fff8da4c5c9 libdyld.dylib`start + 1