From dfba10779b30ee4373b13a9610fe695c1a30213655fb2becf30a1f4a775c7138 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wojtek=20Dziewi=C4=99cki?= Date: Fri, 10 Jan 2014 13:58:57 +0000 Subject: [PATCH 1/3] Accepting request 213467 from home:LPechacek:branches:Base:System There were messages like the following in system log after at daemon was disabled: 2014-01-03T09:19:51.172618+01:00 fmn systemd-sleep[13167]: /usr/lib/systemd/system-sleep/atd.sh exited with exit status 1. These are a result of the atd.sh script leaking the exit code of systemctl. This change to at.sleep prevents leaking systemctl exit code as well as simplifies the script. OBS-URL: https://build.opensuse.org/request/show/213467 OBS-URL: https://build.opensuse.org/package/show/Base:System/at?expand=0&rev=74 --- at.sleep | 19 +++++++++++-------- at.spec | 2 +- 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/at.sleep b/at.sleep index 56bd02e..9f99732 100644 --- a/at.sleep +++ b/at.sleep @@ -1,9 +1,12 @@ #!/bin/sh -case $1/$2 in - pre/*) - systemctl --quiet is-enabled atd && systemctl stop atd - ;; - post/*) - systemctl --quiet is-enabled atd && systemctl restart atd - ;; -esac + +if systemctl --quiet is-enabled atd; then + case $1/$2 in + pre/*) + systemctl stop atd + ;; + post/*) + systemctl restart atd + ;; + esac +fi diff --git a/at.spec b/at.spec index 6e1853b..d58b957 100644 --- a/at.spec +++ b/at.spec @@ -1,7 +1,7 @@ # # spec file for package at # -# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed From 60219c83e1a9a09152a69a1928f560f8344b9d99911c239ce01e46e6645e76d7 Mon Sep 17 00:00:00 2001 From: Stephan Kulow Date: Sat, 25 Jan 2014 06:49:11 +0000 Subject: [PATCH 2/3] Accepting request 214977 from home:aeneas_jaissle:branches:Base:System Added a changelog entry for the previous submit OBS-URL: https://build.opensuse.org/request/show/214977 OBS-URL: https://build.opensuse.org/package/show/Base:System/at?expand=0&rev=75 --- at.changes | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/at.changes b/at.changes index 492a4a9..d5ddf98 100644 --- a/at.changes +++ b/at.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Thu Jan 23 21:15:53 UTC 2014 - aj@ajaissle.de + +- Previous submit (SR#213467 / revision 74): Fixed leaking the exit + code of systemctl in atd.sh. A change to at.sleep prevents + leaking systemctl exit code as well as simplifies the script. + ------------------------------------------------------------------- Tue Nov 12 15:37:29 UTC 2013 - mvyskocil@suse.com From 82df3474f204de34cf5cc68e2a45780c122a4ea15d5691d89a8e373c61d88f8c Mon Sep 17 00:00:00 2001 From: Stephan Kulow Date: Sat, 25 Jan 2014 06:50:06 +0000 Subject: [PATCH 3/3] - Fixed leaking the exit code of systemctl in atd.sh. A change to at.sleep prevents leaking systemctl exit code as well as simplifies the script. OBS-URL: https://build.opensuse.org/package/show/Base:System/at?expand=0&rev=76 --- at.changes | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/at.changes b/at.changes index d5ddf98..a8f16b4 100644 --- a/at.changes +++ b/at.changes @@ -1,9 +1,9 @@ ------------------------------------------------------------------- Thu Jan 23 21:15:53 UTC 2014 - aj@ajaissle.de -- Previous submit (SR#213467 / revision 74): Fixed leaking the exit - code of systemctl in atd.sh. A change to at.sleep prevents - leaking systemctl exit code as well as simplifies the script. +- Fixed leaking the exit code of systemctl in atd.sh. A change + to at.sleep prevents leaking systemctl exit code as well as + simplifies the script. ------------------------------------------------------------------- Tue Nov 12 15:37:29 UTC 2013 - mvyskocil@suse.com