plan9fox/sys
cinap_lenrek db971a6189 kernel: fix stat bugs
In a few places, we where using a fixed buffer of sizeof(Dir)+100
size for stat. This is not correct and fails if the name returned
in stat is long.

This results in being unable to seek to the end of file with a
long filename.

The kernel should do the same thing as dirfstat() from libc;
handling the conversion and buffer allocation and returning a
freeable Dir* pointer.

For this, a new dirchanstat() function was added.

The fstat syscall was not rewriting the name to the last path
element; fix it.

In addition, gracefully handle the mountfix case, reallocating
the buffer to accomidate the required stat length plus
size of the new name so dirsetname() does not fail.
2021-10-23 13:40:06 +00:00
..
doc
games/lib fortunes: unremove 2021-07-08 15:47:49 +00:00
include qsort: ...forgot to include headers in the commit. 2021-08-11 13:10:14 +00:00
lib /sys/lib/acid/pool: format addresses using A format, instead of X (32 bit) 2021-09-25 14:51:23 +00:00
man acmed(8): missed a spot 2021-10-21 02:11:03 +00:00
src kernel: fix stat bugs 2021-10-23 13:40:06 +00:00