Hi People.
I have been reading up on Threads in the win32 API help
file but I am still a little unsure about when to use a
"CriticalSection".
I have an app that sits around listening to a spcecific
port, when it gets a valid connection it spawns a new
thread of the "wroker thread". as follows..
Function WorkerThread&()
CALL sub1 'recieve a file
CALL sub2 'unpack the file
CALL sub3 'process the file
CALL sub4 'pack any outwards files for user
CALL sub5 'send outwards file(s)
Close thread
End Function
Are the subs/functions called from the thred that is created
protected or do I nee to use "CriticalSection" before and
after each call ?
Also are there any guess-timates on how many connections I
could recieve and process like this ?
any help appreciated.
N.
------------------
I forgot to mention that the subs called will also
call other subs/functions.
[This message has been edited by Neil Hosgood (edited January 04, 2001).]
I have been reading up on Threads in the win32 API help
file but I am still a little unsure about when to use a
"CriticalSection".
I have an app that sits around listening to a spcecific
port, when it gets a valid connection it spawns a new
thread of the "wroker thread". as follows..
Function WorkerThread&()
CALL sub1 'recieve a file
CALL sub2 'unpack the file
CALL sub3 'process the file
CALL sub4 'pack any outwards files for user
CALL sub5 'send outwards file(s)
Close thread
End Function
Are the subs/functions called from the thred that is created
protected or do I nee to use "CriticalSection" before and
after each call ?
Also are there any guess-timates on how many connections I
could recieve and process like this ?
any help appreciated.
N.
------------------
I forgot to mention that the subs called will also
call other subs/functions.

[This message has been edited by Neil Hosgood (edited January 04, 2001).]
Comment