Only retrieve the FlashMapManager if a non-empty output FlashMap has been found

Issue: SPR-10937
(cherry picked from commit 4ac6801)
Perform setParent's Environment merging for ClassPathXmlApplicationContext etc constructors with parent argument as well

Issue: SPR-11068
(cherry picked from commit c5fcf19)