More Pstring() stuff and some cosmetics

This commit is contained in:
Jack Jansen 1995-01-18 13:58:04 +00:00
parent 48d071d302
commit d50e4e1c54
4 changed files with 20 additions and 4 deletions

View file

@ -17,14 +17,12 @@ guesstabsize(path)
s[0] = strlen(path);
memcpy(s+1, path, s[0]);
refnum = OpenResFile(s);
/* printf("%s --> refnum=%d\n", path, refnum); */
if (refnum == -1)
return 0;
UseResFile(refnum);
h = GetIndResource('ETAB', 1);
if (h != 0) {
tabsize = (*(short**)h)[1];
/* printf("tabsize=%d\n", tabsize); */
}
CloseResFile(refnum);
return tabsize;

View file

@ -14,7 +14,7 @@ long creator, type;
FInfo info;
unsigned char *pname;
pname = (StringPtr) c2pstr(name);
pname = (StringPtr) Pstring(name);
if ( GetFInfo(pname, 0, &info) < 0 )
return -1;
info.fdType = type;