possible bug?

Forum for general chit-chat or off-topic discussion.

Moderators: CEGUI MVP, CEGUI Team

arbuckle911
Just popping in
Just popping in
Posts: 6
Joined: Sat Nov 25, 2006 01:50

possible bug?

Postby arbuckle911 » Tue Nov 28, 2006 06:24

I'm getting some extremely odd crashes with my CEGUI code.
Read the comments in what I post below

-----------------------------
bool DirectConnect(const CEGUI::EventArgs& args)
{
using namespace CEGUI;
WindowManager& winMgr = WindowManager::getSingleton();
CEGUI::String playStr, ipStr;
Editbox* ipBox = static_cast<Editbox*>(winMgr.getWindow("IPBox"));//THIS CODE WORKS
Editbox* nameBox = static_cast<Editbox*>(winMgr.getWindow("PlayerNameBox"));//THIS CODE WORKS
nameBox->setText("some text");//THIS CODE WORKS
ipBox->setText("some text"); //THIS CODE WORKS
ipStr = nameBox->getText();//THIS CODE CRASHES!
playStr = ipBox->getText();//THIS ALSO CRASHES!
return true;
};
--------------------------------------------
I'm at a loss here because my pointers are working (I can set text) but it crashes with an access violation when reading the data. Even stranger, I can run this just fine in debug mode, I only get the errors with release mode.

EDIT: There are no errors in the log file either...

User avatar
lindquist
CEGUI Team (Retired)
Posts: 770
Joined: Mon Jan 24, 2005 21:20
Location: Copenhagen, Denmark

Postby lindquist » Tue Nov 28, 2006 06:34

the obvious question would be if you are linking against the correct libraries.
CEGUIBase.lib for Release, CEGUIBase_d.lib for Debug. Also the runtime library has to be the same as you built cegui with (Multithreaded DLL, debug for Debug as well)

arbuckle911
Just popping in
Just popping in
Posts: 6
Joined: Sat Nov 25, 2006 01:50

Postby arbuckle911 » Tue Nov 28, 2006 06:45

I double checked the debug and release links, they are fine. I downloaded the pre-compiled dll version, and my release runtime is set to Multi-threaded and my debug is multi-threaded debug.

I just tried a release Multithreaded DLL runtime compile and got the exact same results.

EDIT: I'm using VS.NET 2003 (not express)

arbuckle911
Just popping in
Just popping in
Posts: 6
Joined: Sat Nov 25, 2006 01:50

Postby arbuckle911 » Tue Nov 28, 2006 08:46

ok, I've just built CEGUI from source, and used Multithreaded DLL in both, but same problem.

Pompei2
Home away from home
Home away from home
Posts: 489
Joined: Tue May 23, 2006 16:31

Postby Pompei2 » Thu Nov 30, 2006 20:48

Hmmm some time ago i read something of problems with VS2003 and some libraries ... i can't help much but be sure that alle libraries (even 3rd party used by CEGUI) are compiled to use the same memory routines. sorry, can't help more and i know these are the most awful problems, but i am quite sure that is a link error :(


Return to “Offtopic Discussion”

Who is online

Users browsing this forum: No registered users and 1 guest