981614e483
In write_close() call update_recent_session_locks() before setting $sessionatclose so that it includes $SESSION->recentsessionlocks and doesn't trigger the debugging in check_mutated_closed_session().