The value of ESP was not properly saved across a function call.
by Stefan Lundmark · in Torque Game Engine · 06/19/2007 (12:46 pm) · 0 replies
Please disregard this thread. I was including the Max7 SDK headers, but used the Max 4 libs as I didn't spot that 4 in the lib path. If anyone can learn from my mistake, please do. :)
---------------------------------------------
Still trying to port the Max4 exporter to Max7. Without much success really. Googling tells me that I might need to change the calling convention, but I didn't force it anywhere and it's set as cdecl in the compiler.
It dies on calling getName (), see below.
Any suggestions? The same code looks the same in the Max4 versions, and that works. pNode doesn't seem to be invalid, so why would the name be?
Sorry, I'm just really stuck.
---------------------------------------------
Still trying to port the Max4 exporter to Max7. Without much success really. Googling tells me that I might need to change the calling convention, but I didn't force it anywhere and it's set as cdecl in the compiler.
Quote:
Run-Time Check Failure #0 - The value of ESP was not properly saved across a function call. This is usually a result of calling a function declared with one calling convention with a function pointer declared with a different calling convention.
It dies on calling getName (), see below.
S32 SceneEnumProc::callback(INode *pNode)
{
const char *name = pNode->GetName();
const char *pname = pNode->GetParentNode()->GetName();Quote:
[+] name: 0xcccccccc
[+] pNode: 0x10768600
[+] this: 0x0013e2a0 {file={mFile={handle=0xffffffff currentStatus=Closed capability=0 } mStreamCaps=0 mBuffer=0x11817f1c "" ...} meshNodes={mElementCount=0 mArraySize=0 mArray=0x00000000 ...} skinNodes={mElementCount=0 mArraySize=0 mArray=0x00000000 ...} ...} SceneEnumProc * const
Any suggestions? The same code looks the same in the Max4 versions, and that works. pNode doesn't seem to be invalid, so why would the name be?
Sorry, I'm just really stuck.
About the author