summaryrefslogtreecommitdiffstats
path: root/bftw.h
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2016-02-09 10:34:36 -0500
committerTavian Barnes <tavianator@tavianator.com>2016-02-09 10:40:49 -0500
commit0f09fc54fdf6d5cd453ea0e9fb363756baf87dae (patch)
tree6b69675ba45394c40929ca92c0eb13d1dd53cd1c /bftw.h
parentb46da967104df09edcad706e5e8ef31326a113dd (diff)
downloadbfs-0f09fc54fdf6d5cd453ea0e9fb363756baf87dae.tar.xz
Implement -L/-follow.
Diffstat (limited to 'bftw.h')
-rw-r--r--bftw.h14
1 files changed, 10 insertions, 4 deletions
diff --git a/bftw.h b/bftw.h
index 4b81123..6f6108b 100644
--- a/bftw.h
+++ b/bftw.h
@@ -105,13 +105,19 @@ typedef enum bftw_action bftw_fn(struct BFTW *ftwbuf, void *ptr);
*/
enum bftw_flags {
/** stat() each encountered file. */
- BFTW_STAT = 1 << 0,
+ BFTW_STAT = 1 << 0,
/** Attempt to recover from encountered errors. */
- BFTW_RECOVER = 1 << 1,
+ BFTW_RECOVER = 1 << 1,
/** Visit directories in post-order as well as pre-order. */
- BFTW_DEPTH = 1 << 2,
+ BFTW_DEPTH = 1 << 2,
/** If the initial path is a symbolic link, follow it. */
- BFTW_FOLLOW_ROOT = 1 << 3,
+ BFTW_FOLLOW_ROOT = 1 << 3,
+ /** Follow non-root symbolic links. */
+ BFTW_FOLLOW_NONROOT = 1 << 4,
+ /** Follow all symbolic links. */
+ BFTW_FOLLOW = BFTW_FOLLOW_ROOT | BFTW_FOLLOW_NONROOT,
+ /** Detect directory cycles. */
+ BFTW_DETECT_CYCLES = 1 << 5,
};
/**