|Anonymous | Login | Signup for a new account||2017-11-18 21:27 UTC|
|Main | My View | View Issues | Change Log | Docs|
|Viewing Issue Simple Details|
|ID||Category||Severity||Type||Date Submitted||Last Update|
|0001135||[Online Pubs] System Interfaces||Editorial||Clarification Requested||2017-04-06 11:04||2017-04-08 13:54|
|Reporter||Ralph Corderoy||View Status||public|
|Summary||0001135: Is "all data" when len is 0 a snapshot of file's length?|
"...starting at offset and continuing for len bytes. The specified range need not currently exist in the file. If len is zero, all data following offset is specified."
Does a len of zero mean from offset to the current extent of the file?
Or if the file later grows, is that covered too by this call's advice?
The "need not currently exist" is clear for offset=0 len=100 if the file is currently 42 bytes and later grows to 314, but the len=0 case is not so unambiguous.
Clarification in the wording.
I'd expect the behaviour of offset=0 len=100 to apply to those 100 bytes regardless of how many times the file is truncated and extended.
Similarly, len=0 should apply from offset to the end of the file, adjusting continuously with that end.
|Tags||No tags attached.|
I agree with the Desired Action that this appears to be the intent, but is left more as implementation-defined by the "may use this information" part. An implementation can provide the interface but do no actual access optimizations based on the advice value, as worded, so any zero or positive len value can be ignored, effectively. So either way of interpreting zero conforming, technically.
Additionally, it is ambiguous about how an implementation should handle multiple calls where advice values conflict for a given range, e.g. a call with WILL_NEED on the range 0,100 followed by one with WONT_NEED on the range of 50,0. Is the first call adjusted to 0,50; or the second call's range adjusted to 100,0; should this be considered an error; etc.
As a related issue, the close() interface does not have an ADV marked section saying that advice data set by posix_fadvise() shall be released, leading to possible errors if a fildes handle is reopened as an incompatible file type and previous advice still in effect.
|2017-04-06 11:04||Ralph Corderoy||New Issue|
|2017-04-06 11:04||Ralph Corderoy||Name||=> Ralph Corderoy|
|2017-04-06 11:04||Ralph Corderoy||URL||=> http://pubs.opengroup.org/onlinepubs/9699919799/functions/posix_fadvise.html [^]|
|2017-04-06 11:04||Ralph Corderoy||Section||=> posix_fadvise|
|2017-04-06 11:07||Ralph Corderoy||Issue Monitored: Ralph Corderoy|
|2017-04-08 13:54||shware_systems||Note Added: 0003672|
|Mantis 1.1.6[^] Copyright © 2000 - 2008 Mantis Group|