Here is an example of a thread.
void* thrfun(void* arg)
{
int var;
var = 7;
pthread_exit(NULL);
}
What happens to var when it exits. Is var de allocated, or is var still sitting in memory as a leak?
Is a thread function simply still a function, and all variables inside are local, meaning they get de allocated upon exit?