[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: chmod 0755 behaves like chmod 755
From: |
Mike Frysinger |
Subject: |
Re: chmod 0755 behaves like chmod 755 |
Date: |
Wed, 3 Oct 2007 23:58:00 -0400 |
User-agent: |
KMail/1.9.7 |
On Wednesday 03 October 2007, Paul Eggert wrote:
> Jason Pepas <address@hidden> writes:
> > was there a reason for this? I hardly think someone would put a
> > leading octal 0 in by mistake...
>
> This came up in previous discussion, and the consensus at the time is
> that leading zeros should not matter, just as they don't matter in
> ordinary numeric representation. Other implementations disagree with
> each other on this matter. Obviously there is no standard in this
> area, so portable scripts shouldn't rely on any particular behavior
> for "0755".
well, it is and it isnt ... POSIX is clear on the behavior with files, but
says that it's up to specific implementations how they behave on
directories ... it seems inconsistent to me that doing:
chmod 0755 file
behaves differently than:
chmod 0755 directory
yes, POSIX allows this, but it's hard to swallow the "leading zeros are
irrelevant" logic when it gets qualified according to POSIX and becomes "when
working on a file, leading zeros are significant, but when working on
anything else, leading zeros are insignificant"
-mike
signature.asc
Description: This is a digitally signed message part.
- chmod 0755 behaves like chmod 755, Jason Pepas, 2007/10/02
- Re: chmod 0755 behaves like chmod 755, Andreas Schwab, 2007/10/02
- Re: chmod 0755 behaves like chmod 755, Jason Pepas, 2007/10/03
- Re: chmod 0755 behaves like chmod 755, Paul Eggert, 2007/10/03
- Re: chmod 0755 behaves like chmod 755,
Mike Frysinger <=
- Re: chmod 0755 behaves like chmod 755, Paul Eggert, 2007/10/04
- Re: chmod 0755 behaves like chmod 755, Evan Hunt, 2007/10/04
- Re: chmod 0755 behaves like chmod 755, Paul Eggert, 2007/10/04
- Re: chmod 0755 behaves like chmod 755, Mike Frysinger, 2007/10/05
- Re: chmod 0755 behaves like chmod 755, Paul Eggert, 2007/10/05
Re: chmod 0755 behaves like chmod 755, Bob Proulx, 2007/10/03