differences between NSWorkspace unmountAndEjectDeviceAtURL and unmountAndEjectDeviceAtPath
differences between NSWorkspace unmountAndEjectDeviceAtURL and unmountAndEjectDeviceAtPath
- Subject: differences between NSWorkspace unmountAndEjectDeviceAtURL and unmountAndEjectDeviceAtPath
- From: Jim O'Connor <email@hidden>
- Date: Sun, 2 May 2010 22:27:24 -0800
[[NSWorkspace sharedWorkspace] unmountAndEjectDeviceAtPath:[[NSURL fileURLWithPath:@"/Volumes/Ejectable"] path]]
NSError *error = nil;
[[NSWorkspace sharedWorkspace] unmountAndEjectDeviceAtURL:[NSURL fileURLWithPath:@"/Volumes/Ejectable"] error:&error];
I couldn't get the first to work, so I changed target to 10.6 and tried the second, hoping that the error message would give me a clue what I was doing wrong, but ejectDeviceAtURL succeeds, so I'm no closer to understanding why the first fails.
I've found several other people asking similar questions but never an answer to those questions.
My alternative is to call system with hdiutil detach, which is ugly.
Thanks for any help.
Jim O'Connor _______________________________________________
Do not post admin requests to the list. They will be ignored.
Filesystem-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden