Doing one bad thing won't necessarily make a good person bad, not if it can be rectified and doesn't become a pattern, nor will doing one good thing make a bad person good.
However, if you keep doing bad things you will stop being a good person pretty fast- much faster than a bad person who keeps doing good things will become a good person.
Bad can contain more good before it becomes good, than good can contain bad.
It's that whole "In any compromise between food and poison, death always wins" thing.
So, if you want to be a good person, it is pretty important to avoid doing bad things, because it's a lot harder to regain your good than to lose it.