Remove registration of shutdown handler