[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ProgSoc] Windows thread communication?

----- Original Message -----
From: "Geoff Saxby" <geoffs@nospam.progsoc.uts.edu.au>
To: "Nigel Sheridan-Smith" <nbsherid@nospam.secsme.ee.uts.edu.au>;
Sent: Sunday, May 28, 2000 1:13 AM
Subject: Re: [ProgSoc] Windows thread communication?

> On Fri, May 26, 2000 at 10:29:20AM +1000, Nigel Sheridan-Smith wrote:
> >
> > Many Windows messages rely on a return value or pass pointers to data...
> > this case you will have to find some other way of doing it because
> > can't be guaranteed to be valid unless its synchronous. How about a
> Why won't the pointers be valid? All the threads run in the same memory
> space. If I pass a pointer to some data it should be fine for the
> reciever to read that data. (Assuming that the memory that the pointer
> points to is still valid.)

Because if its a local variable there is no way of guaranteeing that your
code will still be in the same function when the other thread
copies/modifies the data.


You are subscribed to the progsoc mailing list. To unsubscribe, send a
message containing "unsubscribe" to progsoc-request@nospam.progsoc.uts.edu.au.
If you are having trouble, ask owner-progsoc@nospam.progsoc.uts.edu.au for help.