In my opinion (being a gun owner), you should have to get a license to own/purchase a firearm, which involves a gun class(s), just like getting a drivers license. What it really boils down to though, is the parents. You sort of have an idea if your kid is troubled at a certain point, and it's your responsibility to then get a gun safe to keep them out. The cost of a safe is a big factor why most don't though.
I can go on a gun forum, hit the classifieds, and schedule to meet that person and buy the gun with cash, legally. This is one loophole that puts guns in the wrong peoples hands, and should be looked at.