From: Marius Bakke <marius@gnu.org>
To: "Ludovic Courtès" <ludo@gnu.org>, 47172@debbugs.gnu.org
Cc: 48368@debbugs.gnu.org
Subject: bug#48368: bug#47172: Shepherd 0.8.1 tests fail on core-updates
Date: Sun, 23 May 2021 17:23:48 +0200 [thread overview]
Message-ID: <875yz9qxrv.fsf__13968.8555778534$1621783468$gmane$org@gnu.org> (raw)
In-Reply-To: <87v9794l2a.fsf@gnu.org>
[-- Attachment #1: Type: text/plain, Size: 1652 bytes --]
Ludovic Courtès <ludo@gnu.org> skriver:
> Ludovic Courtès <ludo@gnu.org> skribis:
>
>> This turns out to be due to a… miscompilation bug.
>>
>> In (shepherd scripts herd), ‘run-command’ has this code:
>>
>> (let ((sock (open-connection socket-file))
>> (action* (if (and (eq? action 'detailed-status)
>> (memq service '(root shepherd)))
>> 'status
>> action)))
>> …)
>>
>> Problem is that everything works as if (eq? action 'detailed-status)
>> was omitted, such that ‘herd stop root’ is interpreted as ‘herd status
>> root’.
>
> A workaround that works with 3.0.7 is swapping the two ‘and’
> sub-expressions:
>
> diff --git a/modules/shepherd/scripts/herd.scm b/modules/shepherd/scripts/herd.scm
> index 106de1e..39d2e34 100644
> --- a/modules/shepherd/scripts/herd.scm
> +++ b/modules/shepherd/scripts/herd.scm
> @@ -126,8 +126,8 @@ of pairs."
> the daemon via SOCKET-FILE."
> (with-system-error-handling
> (let ((sock (open-connection socket-file))
> - (action* (if (and (eq? action 'detailed-status)
> - (memq service '(root shepherd)))
> + (action* (if (and (memq service '(root shepherd))
> + (eq? action 'detailed-status))
> 'status
> action)))
> ;; Send the command.
Cc'ing the relevant Guile bug:
https://bugs.gnu.org/48368
See also commit 79be6a985799adc6d663890250f4fb7c12f015b4 on
'core-updates' that builds with -O1 as a less satisfactory workaround.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 247 bytes --]
next parent reply other threads:[~2021-05-23 15:23 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <37305bfa08faea95b45a6496623154c2ebab1f11.camel@zaclys.net>
[not found] ` <87zgwl4ui0.fsf@gnu.org>
[not found] ` <87v9794l2a.fsf@gnu.org>
2021-05-23 15:23 ` Marius Bakke [this message]
[not found] ` <875yz9qxrv.fsf@gnu.org>
2021-05-23 21:43 ` bug#48368: bug#47172: Shepherd 0.8.1 tests fail on core-updates Ludovic Courtès
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/guile/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='875yz9qxrv.fsf__13968.8555778534$1621783468$gmane$org@gnu.org' \
--to=marius@gnu.org \
--cc=47172@debbugs.gnu.org \
--cc=48368@debbugs.gnu.org \
--cc=ludo@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).