Is an ungrounded outlet for a gas stove a safety hazard?
Your best bet, from a safety perspective, is to provide GFCI protection to the circuit.   You then label the 3-prong outlet "GFCI Protected - No Equipment Ground".  That will bring it up to code and render it safe. 

The GFCI device can be at the breaker or anywhere appropriate to protect as much of the circuit as you want to protect.