I know the following is poor, but thats why im posting. This is what i have...
Code:
char* myFunc()
{
char* cTime;
struct tm *addedTime;
//...
strftime(cTime, 20, "%m/%d/%y %H:%M:%S", addedTime);

return cTime;
}
So cTime is not initialized properly and causes problems. Ive thought about using new, but how do i delete after returning? So what is the proper way? my knowledge of stl and string containers and such is poor.
Thx.