Merge lp:~xnox/upstart/reboot-fix into lp:upstart

Proposed by Dimitri John Ledkov on 2014-05-09
Status: Merged
Merged at revision: 1621
Proposed branch: lp:~xnox/upstart/reboot-fix
Merge into: lp:upstart
Diff against target: 28 lines (+9/-1)
2 files modified
ChangeLog (+8/-0)
util/reboot.c (+1/-1)
To merge this branch: bzr merge lp:~xnox/upstart/reboot-fix
Reviewer Review Type Date Requested Status
James Hunt 2014-05-09 Approve on 2014-05-15
Review via email: mp+219007@code.launchpad.net
To post a comment you must log in.
James Hunt (jamesodhunt) wrote :

LGTM.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'ChangeLog'
2--- ChangeLog 2014-05-07 16:34:44 +0000
3+++ ChangeLog 2014-05-09 15:24:25 +0000
4@@ -1,3 +1,11 @@
5+2014-05-09 Dimitri John Ledkov <xnox@ubuntu.com>
6+
7+ * util/reboot.c: only use rebootcommand code path in runlevels 0,
8+ 6 or when force is specified as per intended documented behavior
9+ in the manpage. This corrects the bug when rebootcommand mode was
10+ used in error whenever an argument to reboot was passed.
11+ (LP: #1174272)
12+
13 2014-05-07 James Hunt <james.hunt@ubuntu.com>
14
15 * Convert calls to deprecated json_object_object_get() to
16
17=== modified file 'util/reboot.c'
18--- util/reboot.c 2013-08-22 11:13:41 +0000
19+++ util/reboot.c 2014-05-09 15:24:25 +0000
20@@ -188,7 +188,7 @@
21 mode = POWEROFF;
22
23 /* Check for rebootcommand to pass in the syscall */
24- if ((mode == REBOOT) && args && *args) {
25+ if ((mode == REBOOT) && force && args && *args) {
26 mode = REBOOTCOMMAND;
27 rebootcommand = *args;
28 }

Subscribers

People subscribed via source and target branches