San Francisco has Rent Control ordinances, so as long as the unit was legal, she could have stayed there for the rest of her life (which she probably expected).
Saying that if you change the details of a story, then the details are different doesn't actually mean anything and doesn't have any bearing on the story as it happened.
Illegal Units are covered by rent control. Illegal units, such as in-law apartments, are covered by rent control.
Tenants can only be evicted for one of 15 "just causes." Most of these deal with allegations the tenant can dispute (e.g., tenant is violating the lease) but some are "no-fault" like owner move in or Ellis.
http://www.sftu.org/rentcontrol.html