shutdown more cleanly