Path: utzoo!attcan!uunet!mcsun!ukc!harrier.ukc.ac.uk!civet.ukc.ac.uk!mtr From: mtr@ukc.ac.uk (M.T.Russell) Newsgroups: comp.lang.c Subject: Re: access() Message-ID: <240@civet.ukc.ac.uk> Date: 7 Feb 91 11:05:29 GMT References: <15051@smoke.brl.mil> <3345@unisoft.UUCP> <15103@smoke.brl.mil> Reply-To: mtr@ukc.ac.uk (M.T.Russell) Organization: Computing Lab, University of Kent at Canterbury, UK. Lines: 10 In article <15103@smoke.brl.mil> gwyn@smoke.brl.mil (Doug Gwyn) writes: > The safest way to test for file >existence (on UNIX) is to stat() the presumed pathname and see if >it succeeds. On BSD systems lstat() is often better, as stat() will return a wrong negative result for a symbolic link that points to a non-existent file. Mark