How to prevent texture paint painting wrong areas of object?

I have not seen any tutorial about blenders texture paint that explains how to prevent blenders texture paint painting areas that I am not painting. This happens EVERY time when i try to paint in blender something.

Here is an image about how the problem looks like. I believe most artists know the problem and maybe someone even knows how to fix it?

If I apply Subsurf modifier to it, would it help?

I did find from “smart uv project” panel “island margin” -setting. It seems to fix it, since it helps to prevent bleeding. In default it’s 0, but i checked it to 0.2 and for fast test i don’t see that problem anymore.