Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Unhandled exception with sf::String  (Read 1703 times)

0 Members and 1 Guest are viewing this topic.

Asrai

  • Newbie
  • *
  • Posts: 2
    • View Profile
Unhandled exception with sf::String
« on: September 09, 2009, 09:01:47 pm »
I've recently started using SFML and I encountered an error whilst trying to use sf::String.

When I declare an sf::String and run the program it exits with an unhandled exception:

Quote
Unhandled exception at 0x6973c200 in Test.exe: 0xC0000005: Access violation reading location 0x00ed0654.


I have tracked this bug down the declaration of an sf::String, a minimal example that produces the same error is below.

Code: [Select]
#include <SFML/Graphics.hpp>

int main()
{
sf::String MyString;

return EXIT_SUCCESS;
}


Linker input:

Code: [Select]
sfml-graphics-d.lib
sfml-main-d.lib
sfml-system-d.lib
sfml-window-d.lib


SFML_DYNAMIC in the Preprocessor Definitions.

sfml-graphics-d.dll, sfml-system-d.dll and sfml-window-d.dll in the executable folder.

I'm using SFML 1.5. I can provide any more information if necessary. Any ideas, anyone?

[Edit]: I'm using Visual Studio 2008, running on Windows XP SP3.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Unhandled exception with sf::String
« Reply #1 on: September 09, 2009, 09:12:21 pm »
This is a known bug. You can find two workarounds if you search this forum ;)
Laurent Gomila - SFML developer

Asrai

  • Newbie
  • *
  • Posts: 2
    • View Profile
Unhandled exception with sf::String
« Reply #2 on: September 09, 2009, 09:23:32 pm »
I did do a search of the Forums before I posted this, I guess I missed it. I'll check again!

[Edit]: Found the workarounds, can't believe I missed them the first time I searched! Thanks for the quick reply, sorry to re-post about a well known bug :P