From 33d1ad28cba273b94c70ffc22deb6c53b0c1b068 Mon Sep 17 00:00:00 2001 From: Jack Jansen Date: Fri, 2 Jun 2000 21:29:59 +0000 Subject: Replaced GetFInfo and SetFInfo calls with FspGetFInfo and FspSetFInfo calls, which are carbon-compatible. --- Mac/Python/macsetfiletype.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/Mac/Python/macsetfiletype.c b/Mac/Python/macsetfiletype.c index cb2d822..c4b114f 100644 --- a/Mac/Python/macsetfiletype.c +++ b/Mac/Python/macsetfiletype.c @@ -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; } -- cgit v0.12