[cs631apue] Long Print Total
Jan Schaumann
jschauma at stevens.edu
Fri Oct 1 16:54:20 EDT 2021
Timothy Wang <twang77 at stevens.edu> wrote:
> I notice that the total block sizes come first in
> the output. Is there any way to get the directory
> size directly through fts_open or will I have to
> traverse all files via fts_read and get the size via
> stat?
You can't get the size in a single call and do indeed
have to add up the size as you walk the directory.
-Jan
More information about the cs631apue
mailing list