083d65
--- gnome-settings-daemon-40.0.1/plugins/print-notifications/gsd-print-notifications-manager.c
083d65
+++ gnome-settings-daemon-40.0.1/plugins/print-notifications/gsd-print-notifications-manager.c
083d65
@@ -1268,6 +1268,7 @@ scp_handler (GsdPrintNotificationsManage
083d65
                 kill (manager->scp_handler_pid, SIGHUP);
083d65
                 g_spawn_close_pid (manager->scp_handler_pid);
083d65
                 manager->scp_handler_spawned = FALSE;
083d65
+                manager->scp_handler_pid = -1;
083d65
         }
083d65
 }
083d65
 
083d65
@@ -1636,8 +1636,10 @@ gsd_print_notifications_manager_stop (Gs
083d65
                 manager->check_source_id = 0;
083d65
         }
083d65
 
083d65
-        if (manager->subscription_id >= 0)
083d65
+        if (manager->subscription_id >= 0) {
083d65
                 cancel_subscription (manager->subscription_id);
083d65
+                manager->subscription_id = -1;
083d65
+        }
083d65
 
083d65
         g_clear_pointer (&manager->printing_printers, g_hash_table_destroy);
083d65
 
083d65
@@ -1649,6 +1651,7 @@ gsd_print_notifications_manager_stop (Gs
083d65
                         g_source_remove (data->timeout_id);
083d65
         }
083d65
         g_list_free_full (manager->timeouts, free_timeout_data);
083d65
+        manager->timeouts = NULL;
083d65
 
083d65
         for (tmp = manager->active_notifications; tmp; tmp = g_list_next (tmp)) {
083d65
                 reason_data = (ReasonData *) tmp->data;
083d65
@@ -1665,12 +1668,14 @@ gsd_print_notifications_manager_stop (Gs
083d65
                 }
083d65
         }
083d65
         g_list_free_full (manager->active_notifications, free_reason_data);
083d65
+        manager->active_notifications = NULL;
083d65
 
083d65
         for (tmp = manager->held_jobs; tmp; tmp = g_list_next (tmp)) {
083d65
                 job = (HeldJob *) tmp->data;
083d65
                 g_source_remove (job->timeout_id);
083d65
         }
083d65
         g_list_free_full (manager->held_jobs, free_held_job);
083d65
+        manager->held_jobs = NULL;
083d65
 
083d65
         scp_handler (manager, FALSE);
083d65
 }