Re: UFS dirent d_reclen
Jan Schaumann <[email protected]> Thu, 10 Sep 2020 11:49:21 -0400
| Newsgroups | gmane.os.netbsd.devel.general |
|---|---|
| Message-ID | <[email protected]> |
Mouse <[email protected]> wrote: > You're expecting readdir()'s return values to be too similar to the > on-disk format. Well, yes, I suppose. I did think, though, that d_reclen represents what it says it represents: the size of this dirent. > I also conjecture that you're on a 64-bit architecture, on which struct > dirent is padded as necessary for 8-byte alignment That makes sense to me in the context of the whole struct, but if the on-disk format disagrees, is there no way to determine the actual size of that particular dirent? Because it truly is _not_ 16, so what use is d_reclen if it doesn't provide me with the answer to the question "how large is this one directory entry"? -Jan