diff -Nru update-notifier-0.150/debian/changelog update-notifier-0.151/debian/changelog --- update-notifier-0.150/debian/changelog 2014-01-08 13:36:58.000000000 -0500 +++ update-notifier-0.151/debian/changelog 2014-01-10 16:39:28.000000000 -0500 @@ -1,3 +1,10 @@ +update-notifier (0.151) trusty; urgency=low + + * If there are no updates available, still nag the user if a reboot is + required, in case the notification window was dismissed. (LP: #1033226) + + -- Marc Deslauriers Fri, 10 Jan 2014 16:37:56 -0500 + update-notifier (0.150) trusty; urgency=low * Update the location of apport/autoreport from /etc to /var/lib. diff -Nru update-notifier-0.150/src/update.c update-notifier-0.151/src/update.c --- update-notifier-0.150/src/update.c 2013-07-12 13:07:51.000000000 -0400 +++ update-notifier-0.151/src/update.c 2014-01-10 17:13:53.000000000 -0500 @@ -551,6 +551,7 @@ priv->num_upgrades = 0; priv->num_security = 0; int exit_status = 0; + int reboot = 0; GError *error = NULL; char *cmd[] = { "/usr/bin/nice", @@ -558,6 +559,7 @@ UPGRADE_CHECKER, NULL }; char *ret; + struct stat buf; if(g_spawn_sync(NULL, cmd, NULL, G_SPAWN_STDOUT_TO_DEV_NULL, @@ -615,10 +617,10 @@ g_debug_update("%s returned %i (security: %i)", UPGRADE_CHECKER, priv->num_upgrades, priv->num_security); - if (priv->num_upgrades == 0) { + reboot = (stat("/var/run/reboot-required", &buf) == 0); + if ((priv->num_upgrades == 0) && !reboot) { // check if the periodic file is very old - struct stat buf; if ((stat("/var/lib/apt/periodic/update-success-stamp", &buf) == 0) && (time(NULL) - buf.st_mtime > OUTDATED_NAG_AGE) ) g_timeout_add_seconds(OUTDATED_NAG_WAIT, (GSourceFunc)outdated_nag, ta); @@ -641,7 +643,7 @@ update_trayicon_update_tooltip(ta, priv->num_upgrades); tray_applet_ui_set_visible(ta, FALSE); - if (auto_launch_now(ta)) + if (auto_launch_now(ta) || reboot) { g_spawn_command_line_async("nice ionice -c3 update-manager " "--no-update --no-focus-on-map", NULL);