diff -Nru update-notifier-3.164/data/update-motd-updates-available update-notifier-3.165/data/update-motd-updates-available --- update-notifier-3.164/data/update-motd-updates-available 2015-11-13 11:18:38.000000000 +0000 +++ update-notifier-3.165/data/update-motd-updates-available 2016-01-27 21:54:39.000000000 +0000 @@ -6,6 +6,8 @@ # poor mans force if [ "$1" = "--force" ]; then NEED_UPDATE_CHECK=yes +else + NEED_UPDATE_CHECK=no fi # check time when we did the last update check @@ -26,30 +28,28 @@ # let the actual update be asynchronous to avoid stalling apt-get cleanup() { rm -f "$tmpfile"; } -( - # check if we have a list file or sources.list that needs checking - if [ -e "$stamp" ]; then - if [ "$(find "/$StateDir/$ListDir" "/$EtcDir/$SourceList" -type f -newer "$stamp" -print -quit)" ]; then - NEED_UPDATE_CHECK=yes - fi - else - if [ "$(find "/$StateDir/$ListDir" "/$EtcDir/$SourceList" -type f -print -quit)" ]; then - NEED_UPDATE_CHECK=yes - fi +# check if we have a list file or sources.list that needs checking +if [ -e "$stamp" ]; then + if [ "$(find "/$StateDir/$ListDir" "/$EtcDir/$SourceList" -type f -newer "$stamp" -print -quit)" ]; then + NEED_UPDATE_CHECK=yes fi - - tmpfile="" - trap cleanup EXIT - tmpfile=$(mktemp) - - # output something for update-motd - if [ -n "$NEED_UPDATE_CHECK" ]; then - { - - echo "" - /usr/lib/update-notifier/apt-check --human-readable - echo "" - } > "$tmpfile" - mv "$tmpfile" "$stamp" +else + if [ "$(find "/$StateDir/$ListDir" "/$EtcDir/$SourceList" -type f -print -quit)" ]; then + NEED_UPDATE_CHECK=yes fi -) & +fi + +tmpfile="" +trap cleanup EXIT +tmpfile=$(mktemp) + +# output something for update-motd +if [ "$NEED_UPDATE_CHECK" = "yes" ]; then + { + + echo "" + /usr/lib/update-notifier/apt-check --human-readable + echo "" + } > "$tmpfile" + mv "$tmpfile" "$stamp" +fi diff -Nru update-notifier-3.164/debian/changelog update-notifier-3.165/debian/changelog --- update-notifier-3.164/debian/changelog 2015-11-13 11:28:25.000000000 +0000 +++ update-notifier-3.165/debian/changelog 2016-01-27 22:04:45.000000000 +0000 @@ -1,3 +1,13 @@ +update-notifier (3.165) xenial; urgency=medium + + * data/update-motd-updates-available + - do not execute asynchronously as that causes problems with installers + and generally produces unexpected behavior by default (LP: #1527710). + - define NEEDS_CHECK to avoid unintentionally using value from inherrited + environment. + + -- Scott Moser Wed, 27 Jan 2016 17:04:44 -0500 + update-notifier (3.164) xenial; urgency=medium * debian/90-updates-available