nulleric
/Fix-a-Fork
/amendments
/9
learned zip
eric made amendment 9 about 1 year ago
--- main.c Thu Nov 9 08:18:06 2023
+++ main.c Thu Nov 9 08:29:03 2023
@@ -90,6 +90,8 @@ OSErr openFile(unsigned char *fName, short fRefNum, sh
found = true;
else if(isSit15())
found = true;
+ else if(isZip())
+ found = true;
else if(isCpt())
found = true;
@@ -168,6 +170,10 @@ Boolean isCpt()
{
char magic[] = {0x01, 0x00};
return magicCheck(magic, 0, 'PACT', 'CPCT');
+}
+Boolean isZip()
+{
+ return magicCheck("PK", 0, 'PACT', 'CPCT');
}
short strlen(const char *str)
--- main.h Thu Nov 9 08:17:22 2023
+++ main.h Thu Nov 9 08:29:23 2023
@@ -22,5 +22,6 @@ Boolean magicCheck(char *magic, short offset, OSType t
Boolean isBinHex4();
Boolean isSit5();
Boolean isSit15();
+Boolean isZip();
Boolean isCpt();
Boolean isDsk_1024();