I guess about 40 gallons of fuel left
Based on what?
I would assume that these guys run on the absolute minimum of fuel required for the race plus landing plus a very minimal reserve - perhaps just five minutes worth of fuel. Not the standard +10% +alternate +one hour reserve that is taught during PPL VFR training. In that respect, 40 gallons sounds like a lot to me. But I have to admit I don't know the typical fuel flow of such a racer, and I don't know how far into the race this accident happened.