diff options
author | Tavian Barnes <tavianator@tavianator.com> | 2017-11-05 11:02:27 -0500 |
---|---|---|
committer | Tavian Barnes <tavianator@tavianator.com> | 2017-11-05 11:02:27 -0500 |
commit | 7f8bacca4c2b1d35bb65ddf8cbf70fadf1adf66e (patch) | |
tree | 54d1ba2f4f1cbe4a4465b87053bf229909a500c9 /parse.c | |
parent | 3c02f3290804acedfc922ae82ce2a3aca5ca2ec7 (diff) | |
download | bfs-7f8bacca4c2b1d35bb65ddf8cbf70fadf1adf66e.tar.xz |
parse: Support -perm +7777, for compatibility with BSD and old GNU find
Diffstat (limited to 'parse.c')
-rw-r--r-- | parse.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -1795,6 +1795,12 @@ static struct expr *parse_perm(struct parser_state *state, int field, int arg2) expr->mode_cmp = MODE_ANY; ++mode; break; + case '+': + if (mode[1] >= '0' && mode[1] <= '9') { + expr->mode_cmp = MODE_ANY; + ++mode; + } + break; default: expr->mode_cmp = MODE_EXACT; break; |