|Do you know where your variables are?|
Re: Thread safe equivalent of LINUX touch commandby BrowserUk (Pope)
|on Nov 22, 2012 at 15:11 UTC||Need Help??|
What do you mean by "thread-safe"?
If two threads attempt to touch the same file, first one will succeed(*), and then the other will succeed(*).
Of course, it will be impossible to know which thread succeeded first (or last), but the files timestamps will have changed.
And whichever order they do it in, the file will have been touched twice as programmed.
How do you want to define "not thread-safe"?
(*)Where "success" is defined as altering the timestamps on the file to some value.
With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.