It's not too unusual for the strap button on your guitar or bass to become loose. They can take a bit of punishment without your even realising it.
Many of you will be familiar with the 'matchstick trick' where you can insert a matchstick (preferably spent) or toothpick or similar into the worn screw-hole and re-screw the button back on. This can get you through a few gigs or even a bit longer but it shouldn't really be considered a permanent solution—it could get embarrassing when your strap flies off as you're doing an Angus Young duck-walk across the stage.
The best thing to do is to plug the worn hole completely and re-drill a new screw-hole into fresh wood.
The hole shown here has been let go a bit too far. It's had matchstick after matchstick inserted and all that (ahem) screwing has worn away more wood than usual. This one is a bit of an extreme case.
To put it right is the same principle though. Plug and re-drill. In this case, I'm actually going to drill the existing, worn, hole a little to clean it and get rid of the taper that it has. This will allow me to insert a decent piece of new wood that will hold the strap button for the foreseeable future.
In the image above is the piece of mahogany I'll use. I like to match the plug to the guitar wood if possible and I think it's better to use hardwood plugs rather than those softwood dowels you can get in the hardware shops. The only drawback is that I generally have to shape a plug. It's not that big a big deal though, and it gives a better repair.
I'll drill this hole out a bit—it won't be wider than it is at its mouth and it'll be covered by the strap button anyway— and shape that mahogany to fit. Then, I'll glue it in and let it set. A new screw-hole is drilled and the surface given a dab of lacquer to protect the fresh wood (we're not talking refinish-quality here as it's all hidden anyway).
Once done, the remounted strap button should be good for plenty more years of service.