How can I implement the paradigm demonstrated by the code below to run on WinXP?
I want to fork a process or create a thread that shares global variables with the parent process/thread.
The child process/thread monitors the progress of the parent process/thread.
I cannot find documentation for a fork function per se, a Unix term. It might be called something different for WinXP.
I would be happy to use threads instead. But I'm rusty even with Unix application threads; and I know nothing of WinXP application threads.
So I would appreciate it if someone would be kind enough to provide a turnkey implementation that demonstrates the simplest use of process or thread functions for my purpose demonstrated below.
In either case, do "forked" processes and threads share global address space in WinXP, as they do in Unix?
I hope so. I would prefer to avoid the overhead of IPC mechanisms. The "overhead" includes my own relearning curve. :-(
PS: Arrgghh! The GUI screwed up my indentation. I would try to correct it. But the proper indentation appears when I edit the posting. I suppose I need to insert real tabs. Haven't figured out how (yet). My apologies for the unreadability.
PPS: Double arrgghh! Not even real tabs work; and I cannot get the "paste as text" button to behave as I expect. Can someone tell me the trick for posting indented text in this GUI?