summaryrefslogtreecommitdiffstats
path: root/ctx.c
AgeCommit message (Collapse)Author
2022-02-11ctx: Also check ferror(stdout)Tavian Barnes
Previously this was checked for all other files, but for stdout we just checked the return value of fflush(). Checking ferror() makes sure we don't miss any errors that occurred on a previous flush.
2021-09-26Don't truncate files until we know they're not duplicatesTavian Barnes
2021-09-21ctx: Also deduplicate the standard streamsTavian Barnes
This fixes some potential missing output when the same file is used in a redirection and something like -fprint. The main benefit is smarter handling of /dev/stdout, which will now share the CFILE* with cout.
2021-09-15Implement -files0-from FILETavian Barnes
See https://savannah.gnu.org/bugs/?60383 for the development of the corresponding GNU find feature.
2021-09-02eval: Use 512-byte blocks for -ls when POSIXLY_CORRECT is setTavian Barnes
This matches the behaviour of GNU find, and allows bfs to match the output of BSD find as well. Fixes #77.
2021-05-20eval: Raise RLIMIT_NOFILE if possibleTavian Barnes
This lets us keep more open FDs cached in bftw(). The limit is lowered before running -exec commands, in case they're incompatible with a high limit (e.g. due to select()).
2020-12-02Give messages to unconditional assertion failuresTavian Barnes
2020-12-02parse: Clean up debug flag parsing/printingTavian Barnes
2020-11-12Include what I useTavian Barnes
Thanks to https://github.com/include-what-you-use/include-what-you-use
2020-11-12ctx: Add missing #include <limits.h>Tavian Barnes
Spotted at https://github.com/freebsd/freebsd-ports/commit/4d80040cb4c10271b375f3b5d70d2b29dae7fc6f
2020-11-03New -status option to display a status barTavian Barnes
2020-10-06pwcache: Adjust some naming conventionsTavian Barnes
2020-10-06mtab: Adjust some naming conventionsTavian Barnes
2020-10-04parse: Fail if -color is passed and the colors couldn't be parsedTavian Barnes
2020-09-28ctx: Perserve errno better in bfs_ctx_open()Tavian Barnes
2020-09-27Rename struct cmdline to bfs_ctxTavian Barnes
The API remains similar, with some added accessor functions for lazy initialization of the pwcache and mtab.