Using ingredients that aren't fresh will generally negatively impact the flavor of the dish, but does it impact how long the cooked dish will last before it goes bad? For example, if I make two pots of tomato sauce, one with freshly-picked tomatoes and one with tomatoes on their last legs, will the two resulting pots go bad at the same time (assuming everything else about the preparation is the same)?
That is, does the act of cooking result in a chemically different result for each kind (ripeness) of ingredient?
If it does, how much does it depend on the type of ingredient (e.g. meat vs. vegetables) used? How much does it depend on the style of cooking (i.e. it seems that "light" preparations (those that tend towards "more raw") might be more effected than those the have longer preparations.)