cebix / macemu

Basilisk II and SheepShaver Macintosh emulators
1.38k stars 288 forks source link

extfs doesn't support creating a resource fork before a data fork #193

Open belkadan opened 4 years ago

belkadan commented 4 years ago

Running SheepShaver 2.5 on macOS Catalina 19D76, with a Mac OS 9.0 install.

When I use StuffIt Expander to decompress a .sit file that's currently on the mounted "Unix" partition, the resource fork gets dropped. It works fine, however, on the HFS+ startup disk. Looking at the SheepShaver source, my guess is that StuffIt is trying to create the resource fork before the data fork, and therefore it gets dropped due to this access check:

https://github.com/cebix/macemu/blob/a4a2c88ed7d13df0d16c3f8a737fc06f329b70cc/BasiliskII/src/extfs.cpp#L1553-L1556

I haven't fully thought through the implications, but if there's a write-open of a resource fork and the data fork doesn't exist, it should work to create it on demand, right?

RonaldPR commented 4 years ago

In SheepShaver 2.5 builds from current source on github.com/kanjitalk755/macemu , the resource fork issues in shared folder/Unix on APFS hosts (macOS High Sierra and later) are solved. Builds are available for download om emaculation forum.

Op 18 mrt. 2020, om 03:22 heeft Jordan Rose notifications@github.com het volgende geschreven:

Running SheepShaver 2.5 on macOS Catalina 19D76, with a Mac OS 9.0 install.

When I use StuffIt Expander to decompress a .sit file that's currently on the mounted "Unix" partition, the resource fork gets dropped. It works fine, however, on the HFS+ startup disk. Looking at the SheepShaver source, my guess is that StuffIt is trying to create the resource fork before the data fork, and therefore it gets dropped due to this access check:

https://github.com/cebix/macemu/blob/a4a2c88ed7d13df0d16c3f8a737fc06f329b70cc/BasiliskII/src/extfs.cpp#L1554-L1555

I haven't fully thought through the implications, but if there's a write-open of a resource fork and the data fork doesn't exist, it should work to create it on demand, right?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.

belkadan commented 4 years ago

Oh, perfect! Thanks, @RonaldPR.