Why use pwd(1) for getpwd(3C)? (Re: Why use find?)

Chet Ramey chet at cwns1.INS.CWRU.Edu
Fri Oct 12 05:19:36 AEST 1990


In article <23012:Oct1019:12:2790 at kramden.acf.nyu.edu> brnstnd at kramden.acf.nyu.edu (Dan Bernstein) writes:
>In article <1990Oct9.122813.1329 at cbnews.att.com> jbr0 at cbnews.att.com (joseph.a.brownlee) writes:
>  [ why is getpwd() implemented as `pwd` in System V? ]
>
>Because there's no getwd() system call to have the kernel do the job.

BSD doesn't have one either; it's a library routine, at least through
4.3-tahoe.

By the way, the name of the Posix (and S5) routine is getcwd().

Chet
-- 
Chet Ramey			``As I recall, Doug was keen on boxing.  But
Network Services Group		  when he learned to walk, he took up puttin'
Case Western Reserve University	  the boot in the groin.''
chet at ins.CWRU.Edu



More information about the Comp.unix.programmer mailing list