hudara
March 13th, 2003, 07:36 AM
Hi,
Im using Visual Studio 6 (SP-5).
Im trying to do soming very simple using "string" class of the STL.
I'll try to explain it as clear as possible:
1. I have a DLL which exports the function: string GetName();
std::string DLL_EXPIMP GetName()
{
return std::string("My Name");
}
2. I have an application which uses this function
int main(int argc, char* argv[])
{
std::string Temp = GetName();
printf("*** %s ***\n", Temp.c_str());
return 0;
}
The problem is that the application crashes on exit - BUT ONLY ON DEBUG MODE.
Does anybody knows why it is crashing?
Is this beacuse I don't have the latest version of the STL?
How can I know my STL version?
Thank you very much for your help
Guy Hudara
Im using Visual Studio 6 (SP-5).
Im trying to do soming very simple using "string" class of the STL.
I'll try to explain it as clear as possible:
1. I have a DLL which exports the function: string GetName();
std::string DLL_EXPIMP GetName()
{
return std::string("My Name");
}
2. I have an application which uses this function
int main(int argc, char* argv[])
{
std::string Temp = GetName();
printf("*** %s ***\n", Temp.c_str());
return 0;
}
The problem is that the application crashes on exit - BUT ONLY ON DEBUG MODE.
Does anybody knows why it is crashing?
Is this beacuse I don't have the latest version of the STL?
How can I know my STL version?
Thank you very much for your help
Guy Hudara