Kaydet (Commit) 33d1ad28 authored tarafından Jack Jansen's avatar Jack Jansen

Replaced GetFInfo and SetFInfo calls with FspGetFInfo and FspSetFInfo calls,…

Replaced GetFInfo and SetFInfo calls with FspGetFInfo and FspSetFInfo calls, which are carbon-compatible.
üst ee6eeb18
......@@ -42,14 +42,17 @@ char *name;
long creator, type;
{
FInfo info;
FSSpec fss;
unsigned char *pname;
pname = (StringPtr) Pstring(name);
if ( GetFInfo(pname, 0, &info) < 0 )
if (FSMakeFSSpec(0, 0, pname, &fss) < 0 )
return -1;
if ( FSpGetFInfo(&fss, &info) < 0 )
return -1;
info.fdType = type;
info.fdCreator = creator;
return SetFInfo(pname, 0, &info);
return FSpSetFInfo(&fss, &info);
}
long
......@@ -58,9 +61,12 @@ char *name;
{
FInfo info;
unsigned char *pname;
FSSpec fss;
pname = (StringPtr) Pstring(name);
if ( GetFInfo(pname, 0, &info) < 0 )
if (FSMakeFSSpec(0, 0, pname, &fss) < 0 )
return -1;
if ( FSpGetFInfo(&fss, &info) < 0 )
return -1;
return info.fdType;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment