Yes, there is a cleanup process of old users, but rep and existing content become a factor, not just the last visited time.
You can find the details on the SO Blog entry from 2009 When Is An Account “Abandoned”?, but in it Jeff Atwood lays out the 2 major points that are looked at:
We came up with these two rules of thumb. If..
- the user has not visited the site in six months
AND
- the user has not done anything of significance, ever
.. their accounts are effectively abandoned. We don’t believe those users are ever coming back.
And a bit further in the post Jeff explains the specific criteria
We delete cookie-based unregistered accounts when:
- The user has not visited Stack Overflow in six months
AND
- The user has less than 50 reputation, and no visible (not-deleted) posts
We delete OpenID registered accounts when:
- The user has not visited Stack Overflow in six months
AND
- The user has only 1 reputation, no visible posts, and no other accounts on the network
Shog9 also adds that the cleanup process only deletes a handful at a time due to the vast quantity of qualifying accounts, which is could be why the account you saw has no activity but hasn't been deleted (assuming it did have 1 rep).
This is all that is done. Jeff's goes into some detail as to why this is all that is done, but the short version is there is little reason to do so. Accounts on Stack Exchange are extremely lightweight so it really isn't a drain on resources to keep them around.
Beyond Jeff's criteria, you have to understand that deleting a user is probably much more difficult (and painful) than keeping it, and it will have an impact on other users of the site.
When a user is deleted,
- Questions that meet specific score criterion (<0 net score) are deleted. Any user who answered that question stands to lose the rep they earned for that question.
- When a user is deleted, all of their votes are thrown away. Depending on the user and how much they voted, this could result in many users losing hundreds or thousands of rep points as a result.
When considering this, it seems a lot easier for the system and better for the site to just leave the account alone and make the user responsible for deleting their account if they don't want it anymore.