NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Meaning of size of /dev/pts/ files



On 2023-09-25 10:41, Robert Elz wrote:

[...]

RVP answered that for what you're looking at, the actual size, which is
in the stat() results (which applications should always simply ignore for anything which isn't a regular file, symlink, or one of the memory types,
as it is unspecified - and which both ls and exa (whatever that is) are
doing, correctly, is irrelevant (and as RVP indicated, should always be
0, as nothing ever sets it to anything different). Terminal type devices don't get bigger (which is what the size represents) as you write data to
them, they just pass the data through to someplace else, and forget it.
They do tend to count how much they processed, but that's not a size, and is terminal dependant data, so not available via stat() (so ls will certainly
never tell you that number).

All these considerations are very helpful.

Thank you so much to both of you and sorry for the misunderstanding. It was
far simpler than it seemed.

Rocky


Home | Main Index | Thread Index | Old Index