Summary: | utimensat man page error | ||
---|---|---|---|
Product: | Documentation | Reporter: | Jamie Landeg-Jones <jamie> |
Component: | Manual Pages | Assignee: | freebsd-bugs (Nobody) <bugs> |
Status: | Closed Works As Intended | ||
Severity: | Affects Only Me | CC: | doc, jamie, markj |
Priority: | --- | ||
Version: | Latest | ||
Hardware: | Any | ||
OS: | Any |
Description
Jamie Landeg-Jones
2021-08-08 12:39:35 UTC
The code in question is: 3181 setbirthtime = 0; 3182 if (numtimes < 3 && !VOP_GETATTR(vp, &vattr, td->td_ucred) && 3183 timespeccmp(&ts[1], &vattr.va_birthtime, < )) 3184 setbirthtime = 1; i.e., we set setbirthtime = 1, when ts[1] < vattr.va_birthtime. The timespecs are offsets relative to the epoch, so ts[1] < vattr.va_birthtime means that the input time ts[1] is older than the recorded birth time. I believe this agrees with the documentation, so I don't understand where the bug is. Thanks for the detailed response. Please ignore me, I've been an idiot. I did grok the logic (it has to work that way!), and have written a bit of code to manipulate the btime using the logic, but for some reason I misinterpreted the paragraph in the man page to mean the opposite of what was happening. I read it again and again, and even came back to it the next day before posting, and still managed to misread it... Maybe I can blame the Mandela Effect (!) Sorry for wasting your time.. I must buy you a pint! Cheers, Jamie P.S. I couldn't find the "User is a moron" closure status. |