From 46ec0102e5ca0d1167fcce632f981d012682b966 Mon Sep 17 00:00:00 2001 From: jilles Date: Sun, 24 May 2009 15:27:25 +0000 Subject: Fix chflags -h in various cases: do not use link target's flags as original. Patch slightly changed to align more with chmod.c. PR: bin/131999 Submitted by: bde Approved by: ed (mentor) MFC after: 3 weeks --- bin/chflags/chflags.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'bin/chflags/chflags.c') diff --git a/bin/chflags/chflags.c b/bin/chflags/chflags.c index 053a7a7..02137eb 100644 --- a/bin/chflags/chflags.c +++ b/bin/chflags/chflags.c @@ -115,7 +115,7 @@ main(int argc, char *argv[]) fts_options |= FTS_LOGICAL; } } else - fts_options = FTS_LOGICAL; + fts_options = hflag ? FTS_PHYSICAL : FTS_LOGICAL; /* XXX: Why don't chflags and lchflags have compatible prototypes? */ if (hflag) -- cgit v1.1