fix a new race condition related to sessions, caused by fixing a different one.
fix a new race condition related to sessions, caused by fixing a different one.

DrXyzzy/smc,DrXyzzy/smc,sagemathinc/smc,tscholl2/smc,tscholl2/smc,DrXyzzy/smc,sagemathinc/smc,sagemathinc/smc,tscholl2/smc,sagemathinc/smc,DrXyzzy/smc,tscholl2/smc,tscholl2/smc