X

Repairing Permissions and assumptions

Repairing Permissions and assumptions

CNET staff
2 min read

Last week we published an article entitled "Repair Permissions: A False Panacea?." The piece sought to clarify some misconceptions about what exactly the repair permissions process does, and exemplify some valid uses for the procedure as a troubleshooting routine.

Today we'd like to further emphasize some points made in the original article.

The key point is that there are troubleshooting issues that can be solved repairing permissions, though in a perfect development/usage world, there shouldn't be.

Permissions get out of whack when programs make assumptions about the system that are not true. Generally, these assumptions can be labeled bugs, because an application should never make such predictions without knowing them -- with certainty -- to be true.

As one developer told us:

"One could write a huge amount of code trying to account for assumptions that, while they might not be false, the actual possibility of them being false is extremely low. After all, the mere act of calling an API in the system is making an assumption. For example, every Mac OS X system has UNIX underpinnings, and we feel like it's safe to call the "stat" API because that's been on every UNIX system for a long time. But it is an assumption nevertheless. The task of software developers is to balance the delivery of a product against the likelihood of support problems -- some scenarios are so unlikely to occur that it's not worth dealing with them (i.e., the "stat" API not being present on the system), others are likely enough that the programmer must give the user a mechanism to deal with that situation ("The file server (blah) is no longer responding on the network. Would you like to backup your file to a locally connected disk?"). There are lots of factors here to be balanced -- time to market, support costs, competition, etc."

As such, developers of a particular product may decide that the assumption that disk permissions will be a certain way is a risk worth taking. After all, Apple includes Disk Utility -- which can repair the problems caused by aforementioned permissions -- with every shipping copy of Mac OS X.

Inevitably, the group of developers who -- perhaps erroneously -- makes assumptions about permissions includes Apple itself. There are times when Apple developers -- just like other developers -- take the risk that the system will behave according to some guideline, and they fail to account for the possibility that it doesn't.

The upshot is that there are cases where repairing permissions even makes Apple's own products behave better.

As we stated earlier, there should never be a problem where a permissions repair solves issues with a particular product. As such, when repairing permissions does work to resolve an issue, it's important to contact the developer in order for further investigation -- and perhaps some re-thinking of assumptions -- to occur.

Feedback? Late-breakers@macfixit.com.

Resources

  • "Repair Permissions: A False Panacea?.
  • Late-breakers@macfixit.com
  • More from Late-Breakers