/bin/pwd

Guy Harris guy at auspex.auspex.com
Sat Sep 15 06:49:45 AEST 1990


>On System V style systems, getcwd(3) popen(3)'s "/bin/pwd" to get 
>the current workind directory.

On some, anyway.  That's how S5 from AT&T - at least prior to S5R4 -
implements "getcwd()", but you could have "getcwd()" be the routine that
does the work (just like "getwd()", but with bounds checking) and have
"/bin/pwd" just call it.  (SGI basically does that in recent releases,
although "getcwd()" ends up calling a BSD-flavored "getwd()" to do the
actual work).  Dunno whether S5R4 does that or not.



More information about the Comp.unix.questions mailing list