To be fair, throughout the dragon ball franchise, they do try and stress that while Goku has morals, he is not a hero - his main goal is just to fight the strongest beings he can find, and win.
If Cell and Frieza weren't direct threats to his family, Goku would 100% have let them get stronger so he had more sparring partners.
Hell, in one of the series (can't remember if it was non-cannon GT or not) he straight up trains Uub, Buu's non-evil reincarnation.