Allegedly restricted files needlessly obstruct emptying the trash
||Date Originated:||04-Jan-2017 03:08 PM|
|Product:||macOS + SDK
||Product Version:||10.12.2 (16C67)|
If a file with "restricted" lineage is in the Trash, even if the user has permission to delete it, the Trash cannot be emptied and leads to nonsensical messages being presented to the user.
Steps to Reproduce:
1. Open Terminal
2. Run these commands (use 501 or the user name of the current user):
sudo ditto /System/Library/CoreServices/ControlStrip.app ~/.Trash/ControlStrip.app
sudo chown -R 501 ~/.Trash/ControlStrip.app
3. From the Finder, attempt to empty the trash.
The Trash, being filled with files that are wholly owned by the user, should be emptied.
"Some items in the Trash cannot be deleted because of System Integrity Protection."
If you press "Continue", another alert:
"The operation can’t be completed because the item “ControlStrip” is in use."
It should be noted here that "ControlStrip" is not actually in use.
Now, if you go back to Terminal and simply "rm -rf ~/.Trash/ControlStrip.app", the files are removed from the trash and no special permissions or warnings are required or generated.
Reports posted here will not necessarily be seen by Apple.
All problems should be submitted at bugreport.apple.com before they are posted here.
Please only post information for Radars that you have filed yourself, and please do
not include Apple confidential information in your posts. Thank you!