mirror of
https://github.com/opnsense/src.git
synced 2026-07-15 20:13:02 -04:00
Besides being a little hard to parse through visually, this had its own bug of inspecting st->st_mode to determine what to pass to devname(3), which is only correct for st_rdev. For st_dev, you're likely to be looking at files or directories and attempting to assess what device they're located on, so the mode is meaningless- we just have to assume that our filesystems are on character devices and attempt to resolve st_dev as such. Approved by: re (cperciva) Reviewed by: des, kib (previous version) Differential Revision: https://reviews.freebsd.org/D56565 (cherry picked from commit 4d4acdbfc22c84081037f31cff4fb03d18373036) stat: The devname test case requires root Fixes: 4d4acdbfc22c ("stat: fix use of devname(3)") (cherry picked from commit 72b1aae09bf0bcc01c76df757699e27ad7cf7ecc) stat: Set the timezone before testing -t flag The test assumes UTC, which is what I use on my development systems and clearly what is used on our CI runners. MFC after: 1 week Sponsored by: Klara, Inc. Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D56836 (cherry picked from commit 49e496d2776870fb36ed8ea4c8139b5eb9f7f747) stat: Expand devname test case Test what happens when we ask for the rdev of a non-device. MFC after: 1 week Sponsored by: Klara, Inc. Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D56838 (cherry picked from commit 2c88636e0e7a0316d5e6d146874bdb2751f75c40) (cherry picked from commit 88f5520fa564ef1050bab6e091ead4040eb6d170) |
||
|---|---|---|
| .. | ||
| tests | ||
| Makefile | ||
| Makefile.depend | ||
| stat.1 | ||
| stat.c | ||