Re: Finder f*ck-ups
Re: Finder f*ck-ups
- Subject: Re: Finder f*ck-ups
- From: Matt Deatherage <email@hidden>
- Date: Thu, 18 Aug 2005 14:45:19 -0500
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 8/18/05 at 1:51 PM, Martin Orpen <email@hidden> wrote:
> I call files disappearing before your eyes "pathetic". I call
> undocumented changes that can screw your scripts and apps "pathetic"
> too.
I call them "bugs" unless I have specific evidence that someone meant for it to work that way. I do not attribute to malicious behavior what can be more easily explained by the common, every day errors of programming.
> Put a DVD in your drive and copy the VIDEO_TS folder to your hard
> disk. You'll find that some disks will copy. Others won't -
> especially those that are Region 1. You get a "Don't have sufficient
> privileges error" or "some data could not be read or written (-36)".
>
> Click on a the VOB data on a disk that won't copy and you'll find
> that the files disappear before your eyes.
>
> Put the troublesome disk in a Mac running Panther and everything
> works as expected.
<http://bugreporter.apple.com/>. More importantly, *name a disc.* Identify a DVD on which you can make this fail every time on your G4 and G5 machines. I'll bet you a muffin at WWDC someday that Apple will go out and at least rent, if not buy, the DVD to try to reproduce and fix the bug. (The more widely available the disc, the easier it will be to reproduce the bug.)
Your statement "especially those that are Region 1" implies that your drive is not set to Region 1, or that you never have the trouble with discs set to other regions. If this is true, be sure to say so in the bug report. It may depend on the region settings of the drive and they'll need to know that. The full system profiler report will help.
> I've tested this on a couple of G4s and 2 G5s and with internal and
> external DVD drives before posting - but what do I know as your
> obviously the expert around here... be sure to post back if you've
> got something useful to say - or just STFU...
I don't waste time listing credentials, but let's see what you've reported here.
According to the currently-installed version of MacErrors.h (and, in fact, according to every version of Errors.a or Errors.p going back to 1984), error -36 is the dreaded "I/O error," one the header file's comment still describes as "(bummers)".
With few exceptions, an "I/O error" is a generic error returned by device drivers that can't be translated into something more meaningful by file system code. The HFS or UFS code knows when directory structures are damaged even if the hardware can read the blocks from disk. If the hardware can't read the blocks from disk, there's usually no specific Mac OS error code that matches whatever low-level information the drive returns, and it gets mapped to -36.
It's also possible that file system code itself will return error -36 if there's no better error code to describe some kind of disc funkiness, but it is less common.
Your description above is unclear, but it sounds like you're getting *either* privilege errors *or* I/O errors when trying to copy files, but not both on the same disc. Plus, I see in your original message that you state:
> If I need to copy VOB files I keep getting permission errors and then
> the files start disappearing from the GUI. I can still see them from
> the shell, but even cp or mv won't move the data from DVD to disk.
Since the Finder doesn't use cp or mv (or vice-versa), this should have been your big clue that the Finder *is not at fault.* Try another program to copy the files, anything from Path Finder to File Buddy, and I'll bet you can't copy them that way either.
If I had to guess, I would say that either the DVD driver or the UDF file system code has new restrictions in Tiger that prohibit copying files in some cases. The code may be trying to return a privilege error if you try to read the files in an unauthorized way, and that in turn may be propagating in a way that confuses higher-level code. Typically, if Finder removes an object from a window, it got a file system notification that the directory changed, as in you no longer have privileges to see that object. The UDF file system might be showing you everything until you try to copy it.
(If this is true, then there is probably a secret API you have to use to read these files, one that the DVD playback framework uses but that normal file copying programs do not. I don't think Mac The Ripper has this problem, but I don't use it so I don't know for sure.) I see some things in the DVD framework that imply this, but nothing concrete (you have to use its functions to open a VIDEO_TS folder instead of passing in files yourself).
I put in a region 1 disk, since I had one within arm's reach, and tried to copy the VIDEO_TS folder. I got a privilege error. I tried with cp and it appeared to try really hard on most of the ".VOB" files but never returned any output in the time I had to spend on it. No utility I had revealed any special permissions, but none of them could copy some of the ".VOB" files.
I'm guessing this is a change in the UDF file system code, especially since it's one of the few file systems not part of the Darwin open-source tree so I can't go look at the code and see. I can't see any privilege errors that would cause normal problems, but every file copying code I tried hung up on it. All the files appear to belong to me and have a creation date of exactly when the disk was mounted, though I think that's how UDF usually works.
Whatever it is, it's obviously at a lower level than the Finder. If functionality was removed, it was probably forced by licensing agreements, and Apple may not even be allowed to discuss it for that reason. You know Hollywood - close your eyes real hard and no one will figure anything out.
Whether Apple can let you copy these files or not, Finder should at least give you a reasonable error message, and tools like "cp" should not spin indefinitely trying to do it. The UDF file system should return access privileges that make clear what's going to happen. If we're going to complain, it should be about the right context. File your bug.
> Maybe you can put the problem into words for me then - as my Xcode
> apps haven't gotten anywhere near the size of the Finder yet.
When they do, you'll feel differently, especially about users who accuse you of bad intentions for common bugs.
Or perhaps you'll blame the Finder, because it's so much easier.
- --
Matt Deatherage <email@hidden>
GCSF, Incorporated <http://www.macjournals.com>
"Wanting to meet an author because you like his work is like wanting
to meet a duck because you like pâté."
-- Margaret Atwood
-----BEGIN PGP SIGNATURE-----
Version: PGP Desktop 9.0.2 (Build 2425)
iQA/AwUBQwTlUOQJS+YigHjzEQK4UACgt4oBa1cRblZQd8c9Xtc12hT5M+kAoNYn
mAm5mMp6gSxA6468BNYyyzm9
=bBMq
-----END PGP SIGNATURE-----
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden