Cost, essentially.
If the code for a project is fully owned by Apple, for example, then even slapping on a small disclaimer like "this is for noncommercial educational use only" etc requires a few levels of internal authorisation and their own legal dept, as we've seen. For a project that's coming up to 30 years old, to even get to the state of knowing the code was entirely in-house may require digging through documentation - not all of which may exist by now - and validating that legal rights to the code do indeed lie with the company as it is today, and that's before checking that there aren't other issues with code release like trade secrets, in-house wilful copyright violations of competitors, or other illegal code. Who in a company really remembers precisely which code is unlawfully involved in making competitor's products look bad, if that were ever implemented in just a tiny fraction of coding projects?
For flagship products where the history is interesting in itself, like macpaint, that may be relatively simple and only require a small amount of digging. For the tens of thousands of jobs spanning five decades like Apple have, that could get really tedious really quickly.