January 5th, 2013, 12:47 PM
Join Date: Jan 2013
Time spent in forums: 13 m 59 sec
Reputation Power: 0
Creating a thread
I wrote the following code:
void ThreadFunction (int* index)
(*index) = (*index)+1;
ReadPicThread=CreateThread( NULL, 0 /*use default stack size*/, (LPTHREAD_START_ROUTINE) ThreadFunction /* thread function*/,
&index /* argument to thread function */,0 ,NULL /* returns the thread identifier */ );
Unfortunately, This code pass compilation, but it doesn't print anything on the screen. I was trying to put a breakpint, and once I operate the debug mode (F5), the program breaks down.
What is the problem ?
Last edited by MatanBarLev : January 5th, 2013 at 01:30 PM.