Sender: rich AT phekda DOT freeserve DOT co DOT uk Message-ID: <3D05B70B.F8A8EE2C@phekda.freeserve.co.uk> Date: Tue, 11 Jun 2002 09:38:35 +0100 From: Richard Dawe X-Mailer: Mozilla 4.77 [en] (X11; U; Linux 2.2.19 i586) X-Accept-Language: de,fr MIME-Version: 1.0 To: djgpp-workers AT delorie DOT com Subject: Re: FSEXT hooks and symlinks References: <1023716516 DOT 31679 DOT 5 DOT camel AT bender DOT falconsoft DOT be> <3D052A8B DOT 9130E7EF AT phekda DOT freeserve DOT co DOT uk> <200206110023 DOT g5B0NmY22830 AT envy DOT delorie DOT com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Reply-To: djgpp-workers AT delorie DOT com Hello. DJ Delorie wrote: > > > unlink: removes the symlink, i.e. doesn't dereference the symlink > > remove: removes the target of the symlink, i.e. resolves the symlink > > No. Linux (and every other *nix I can remember) doesn't do this - > it's always the symlink that's removed, never the target. I don't > think there *is* a way to remove the target of a symlink without > reading the symlink yourself and figuring out what it's pointing to. Yes. Here's what draft 7 of the Austin Group's new POSIX standard says about remove on page 1702 of the System Interfaces manual: "If path does not name a directory, remove(path) shall be equivalent to unlink(path). If path names a directory, remove(path) shall be equivalent to rmdir(path)." Thanks, bye, Rich =] -- Richard Dawe [ http://www.phekda.freeserve.co.uk/richdawe/ ]