[comp.sys.mac.programmer] "getpwd

taylor@hplabsz.HP.COM (Dave Taylor) (03/10/89)

I talked to some friendly chaps at Symantec today, and they
told me that there are a couple of C implementations of the
"getpwd()" routine availble on Genie and CompuServe.  I
need it for some software I'm porting, and I have no access
to either system ...

Does anyone out there in net-land have an implementation of
said routine or access to either BBS that they could download
the source in question and email it to me?  

Conceptually the problem is pretty straightforward; you simply
build up the path name in reverse by starting where you are
and doing a GetVol(), storing the name of the current directory
name, obtaining the 'parent directory' handle, then changing
directories into that new directory.  Repeat until the parent
directory is "2" or otherwise indicates a Root Volume.

If anyone can help, I would be very appreciative.

			Thanks!	
						-- Dave Taylor

Intuitive Systems
Los Altos, California

Guest of HP Laboratories: taylor@hplabs.hp.com