I've worked on plenty of good codebases. I think the key is continuous improvement. The code from 5 years ago is always going to be worse than today's code, but as long as you're able to improve code as you work on it it doesn't get too bad.
Once when I was interviewing for a job, I was given and offer and I accepted it conditionally. I asked to sit with a senior developer for 30 minutes and browse the code. Turns out it was in great shape and the person that gave me the walkthrough was one of the greatest programmers I've ever had the pleasure to work with.
No. This company's main product (the one I would be working on) had been around for a long time so I was concerned about what kind of shape the code was in.