There are different kinds of intelligence, and they often don't correlate to each other. A brilliant coder can absolutely be an emotional infant. It will handicap their career, for sure, but doesn't entirely preclude their ability to solve certain kinds of problems.
I don't think I've seen this be the case -- since there are quite a few crappy and/or poorly paying jobs (in comparison) that become desperate for workers, there's plenty of room for abusive and jerky people.
That's ignoring other broken parts of the system, such as nepotism.