On 2012-09-16, at 6:41 AM, David Levine wrote:
Good point. There isn't a clean way to pass the fd with
the existing code. Do you see any problems with this:
if ((fd == open (file, O_CREAT | O_EXCL), mode) >= 0) {
close (fd);
break;
}
and later . . .
fopen (file, "w") . . .
Well, there's the obvious race condition ... _______________________________________________ Nmh-workers mailing list Nmh-workers(_at_)nongnu(_dot_)org https://lists.nongnu.org/mailman/listinfo/nmh-workers
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: [Nmh-workers] mhstore -clobber, David Levine |
|---|---|
| Next by Date: | Re: [Nmh-workers] mhstore -clobber, Lyndon Nerenberg |
| Previous by Thread: | Re: [Nmh-workers] mhstore -clobber, David Levine |
| Next by Thread: | Re: [Nmh-workers] mhstore -clobber, Lyndon Nerenberg |
| Indexes: | [Date] [Thread] [Top] [All Lists] |