If someone finds that bug and uses it to their advantage, the casino will find out about it sooner or later and punish that person for rigging the casino. But if that person reports it to the casino so the casino can fix the bug, the casino will not penalize you and may even reward you for helping the casino find the bug. Now, what is a person's purpose or motive after he knows there is a bug in the casino? Will he report it to the casino or use it himself?
Most likely he will use it as long as it's hidden and no one knows about it but mostly as well he will be found out. But as soon as he found out, he will be in trouble unless he knows how to disappear before that even happen. Because of greed, most people don't always stop when they find a loophole in gambling, they mostly abused the bugs in order to gain more money at the end of the day greed will hunt them and they will gonna lose their money because of that, just like what we heard from the stories of others.
Until a gambler can control his greed, he will only lose. A gambler must remember that if he does any kind of cheating then he must be found guilty at some point. He may be temporarily benefited by the cheat but in the future he will definitely be responsible for his misdeeds. Moreover, I am not aware of any instance where someone has cheated and earned money in gambling. Every gambling site must conduct gambling with the most skilled manpower. Any type of wrongdoing can be found out immediately and if found guilty of such crime he definitely be under the law enforcement.