Here's how the stress system works. Say you're studying for difficult exams, and you find out that material was included and you only have 2 hours for the test.
When you experience sudden stress or danger, your brain instantly signals your body to turn out a hormone called cortisol. It in turn relays the message throughout the body to use you for a life-saving response. Your heart starts speeding up increasing the cardiac output. You become highly attentive and alert, even vigilant. Blood vessels constrict and divert the flow of blood from leisurely processes such as digestion to fast-acting muscles. Metabolism shifts too, and energy is made rapidly available to your muscles, readying them for action.
When it reaches the brain it commands the brain to cease the body's production of the hormone.
In other words when you experience this sudden episodes of stress it is clear that your body needs food to satisfy this excess of adrenal production.
In my opinion you should be looking at more ehalthy ways of controling that spike such as moderate exercise and regular meditation. Practicing a healthy lifestyle will help your body more resilient and prepared to "war" much better next time.
Read this study
Stress Eating and the Reward system
I hope this helps!