So long as you keep your greed under control and don't start betting amounts you can't afford to lose, then gambling isn't a threat.
In reality, it's only a threat for those with even very low will power, or extreme risk takers that don't know when to call it quits. As such, anybody who has either of these two personality types should probably avoid gambling, as this is an industry where self control is an absolute must.
With that said, it might not be something that is entirely possible to control,
since it appears to have a genetic basis: https://www.sciencedaily.com/releases/2019/10/191009131740.htmThat's an interesting research, only I'm afraid it can serve as an excuse for not fighting their addiction for some addicted gamblers. Many of us are genetically predisposed to many bad things, such as obesity, promiscuity, alcoholism etc. The key is to find strength within yourself to challenge those predispositions, and, in fact, many brave people succeed in that. It is much more interesting to be one of them, than to be of the whining losers blaming genetics for their failure.