also set cur dir for standard get/put file

This commit is contained in:
Guido van Rossum 1995-02-20 23:41:35 +00:00
parent 86b4049b87
commit bcf3b56ea7
1 changed files with 9 additions and 0 deletions

View File

@ -4,6 +4,10 @@
#include "macdefs.h"
/* Last directory used by Standard File */
#define SFSaveDisk (*(short *)0x214)
#define CurDirStore (*(long *)0x398)
/* Change current directory. */
int
@ -19,5 +23,10 @@ chdir(path)
errno= ENOENT;
return -1;
}
if (PBHGetVol(&pb, FALSE) == noErr) {
/* Set the Standard File directory */
SFSaveDisk= -pb.ioWDVRefNum;
CurDirStore= pb.ioWDDirID;
}
return 0;
}