However, as you have said, it is a problem once you let that adrenaline rush control you. The tendency is the thing which happened to you—lose. Well, since you already know the possible outcome, I hope you learned your lesson.
But if you have already set your mind that you will only gamble a specific amount day(s) before going to the casino or before going to your favorite gambling site, then most probably you'll save yourself from bigger loss. However, you still have to make sure that you will follow that mind set and not let greed take over you.