I need to use a char * buf which size augment gradually.
The way I do it is not working I guess that what crashes the program.
Do I need to Free it everytime or can I just Allocate a new size without Freeing it before?
Code:// global
char * buf;
while(1)
{
buf = (char*) GlobalAlloc(GMEM_FIXED, newsize);
FunctionThatUses_buf();
GlobalFree(buf);
Sleep(1000 * 30);
}