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

Author Topic: App Currupted buffer overflow  (Read 2258 times)

0 Members and 2 Guests are viewing this topic.

Ceryni

  • Newbie
  • *
  • Posts: 4
    • View Profile
App Currupted buffer overflow
« on: November 15, 2010, 08:10:56 pm »
Hi,

I know that many people had that problem and i did everything u said in the other threads but i cant solve the problem.

I use the -d libs and included everything that was said in the tutorial.

Code: [Select]

#include <SFML/System.hpp>
#include <SFML/Window.hpp>
#include <iostream>

using namespace std;
using namespace sf;

int main()
{
Window App(VideoMode(800,600,32), "SFML Window");
App.Create(VideoMode(800,600,32),"SFML Window");

    // Start main loop
while (App.IsOpened())
    {
Event Event;
while(App.GetEvent(Event))
{

if (Event.Type == Event::Closed)
App.Close();


if ((Event.Type == Event::KeyPressed) && (Event.Key.Code == Key::Escape))
App.Close();

}
        App.Display();
    }

    return EXIT_SUCCESS;
}


thx for your help.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
App Currupted buffer overflow
« Reply #1 on: November 15, 2010, 08:35:39 pm »
Quote
I use the -d libs

...in Debug configuration (not Release)?

Also make sure that you use the corresponding version of Visual C++ (there are no precompiled libraries for 2010, if that's what you use).
Laurent Gomila - SFML developer

Ceryni

  • Newbie
  • *
  • Posts: 4
    • View Profile
App Currupted buffer overflow
« Reply #2 on: November 15, 2010, 08:49:30 pm »
i use visual 2008 express edition and i only use -d lib's in debug mode.
I've read that before so i installed it and deinstalled 2010.

now there is a new error
Link1104 Data sfml-system-d.lib;sfml-window-d.lib couldn't be opened
all dll's are in the project directory.

Hiura

  • SFML Team
  • Hero Member
  • *****
  • Posts: 4321
    • View Profile
    • Email
App Currupted buffer overflow
« Reply #3 on: November 15, 2010, 11:42:50 pm »
Maybe you have copied into the wrong directory the .lib ?
Or if you copied them into a non-standard directory you forgot to to add this dir to the search path for lib ?
SFML / OS X developer

Ceryni

  • Newbie
  • *
  • Posts: 4
    • View Profile
App Currupted buffer overflow
« Reply #4 on: November 16, 2010, 06:48:25 am »
Projects/tutorials/tutorials (tutorials is the projekt name)  here are my libs.

Hiura

  • SFML Team
  • Hero Member
  • *****
  • Posts: 4321
    • View Profile
    • Email
App Currupted buffer overflow
« Reply #5 on: November 16, 2010, 10:12:42 am »
Quote from: "Tutorial VC"
Copy the SFML development files to your Visual Studio installation directory

Copy SFML-x.y\include\SFML to the VC\include directory of your Visual Studio installation (so that you obtain VC\include\SFML)
Copy the *.lib files in SFML-x.y\lib to the VC\lib directory of your Visual Studio installation

Leave the SFML files where you want, and setup Visual Studio so that it can find them

Go to the Tools / Options menu, then to Projects and Solutions / VC++ Directories
In Include files, add SFML-x.y\include
In Library files, add SFML-x.y\lib
SFML / OS X developer

Ceryni

  • Newbie
  • *
  • Posts: 4
    • View Profile
App Currupted buffer overflow
« Reply #6 on: November 16, 2010, 12:21:11 pm »
i've done the second. but i will try to do it how its described in the first way.

edit: the same problem