Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
* chmod(1) bug [OSF/1 V3.0]
@ 1995-01-04 16:19 Mark Bartelt
  1995-01-04 19:10 ` Steve Strange
  0 siblings, 1 reply; 2+ messages in thread
From: Mark Bartelt @ 1995-01-04 16:19 UTC (permalink / raw)


Take a look at the following:

  opossum> ls -l
  total 1
  lrwxrwxrwx   1 bozo     system         3 Jan  4 10:49 bar -> foo
  -rw-rw-r--   1 bozo     system         4 Jan  4 10:49 foo
  opossum> 
  opossum> chmod g-w bar
  opossum> 
  opossum> ls -l
  total 1
  lrwxrwxrwx   1 bozo     system         3 Jan  4 10:49 bar -> foo
  -rwxr-xrwx   1 bozo     system         4 Jan  4 10:49 foo
     ^  ^ ^^
     !!!!!!!

It looks as if chmod(1) is picking up the mode of the symlink itself
(rather than the mode of the file to which the symlink points) to use
as the value in which to {set,clear} bits to produce the new mode that
gets assigned to the target file.

PS:  Different (though related) question ...  Is there any way to set
the mode which gets assigned to symlinks?  Yeah, I *know* the mode of
a symlink is irrelevant (well, except for bugs like the one reported
above ;-), but IRIX gives them mode 0000, which makes them stand out
a bit more nicely in a "ls -l" listing than does OSF/1's (and SunOS's)
mode 0777.  (Didn't OSF/1 V1.x make them mode 0755?)

Mark Bartelt                                              416/978-5619
Canadian Institute for                           mark@cita.toronto.edu
Theoretical Astrophysics                         mark@cita.utoronto.ca

"Clothes not busy being worn are busy drying." - Dylan, on laundry day
         [ singing "It's all right, ma (I'm only bleaching)" ]


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: chmod(1) bug [OSF/1 V3.0]
  1995-01-04 16:19 chmod(1) bug [OSF/1 V3.0] Mark Bartelt
@ 1995-01-04 19:10 ` Steve Strange
  0 siblings, 0 replies; 2+ messages in thread
From: Steve Strange @ 1995-01-04 19:10 UTC (permalink / raw)


In article <D1w2p7.38u@info.physics.utoronto.ca> sysmark@helios.physics.utoronto.ca (Mark Bartelt) writes:

>   Take a look at the following:
>
>     opossum> ls -l
>     total 1
>     lrwxrwxrwx   1 bozo     system         3 Jan  4 10:49 bar -> foo
>     -rw-rw-r--   1 bozo     system         4 Jan  4 10:49 foo
>     opossum> 
>     opossum> chmod g-w bar
>     opossum> 
>     opossum> ls -l
>     total 1
>     lrwxrwxrwx   1 bozo     system         3 Jan  4 10:49 bar -> foo
>     -rwxr-xrwx   1 bozo     system         4 Jan  4 10:49 foo
>	^  ^ ^^
>	!!!!!!!

>   It looks as if chmod(1) is picking up the mode of the symlink itself
>   (rather than the mode of the file to which the symlink points) to use
>   as the value in which to {set,clear} bits to produce the new mode that
>   gets assigned to the target file.

Yes, it's a known bug, and the fix will appear in V3.2.  Thanks for
the posting.

>   PS:  Different (though related) question ...  Is there any way to set
>   the mode which gets assigned to symlinks? 

I'm not aware of any way to do this.  There is at least one product,
namely DCE DFS, that relies on symlink permission bits to be set as
they are (unfortunately).  You're right about them not being
meaningful in general, though.

	Steve
--
Steve Strange
Digital Equipment Corporation, Nashua, NH
DCE DFS for DEC OSF/1 -- Development
strange@zk3.dec.com


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~1995-01-04 19:10 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1995-01-04 16:19 chmod(1) bug [OSF/1 V3.0] Mark Bartelt
1995-01-04 19:10 ` Steve Strange

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox