supervision - discussion about system services, daemon supervision, init, runlevel management, and tools such as s6 and runit
 help / color / mirror / Atom feed
From: Christian Hohnstaedt <christian@hohnstaedt.de>
To: supervision@list.skarnet.org
Cc: Christian Hohnstaedt <christian@hohnstaedt.de>
Subject: [PATCH] s6-rc-compile: Fix setting of flag-essential
Date: Thu,  3 Jun 2021 23:08:35 +0200
Message-ID: <20210603210835.6111-1-christian@hohnstaedt.de> (raw)

Don't set the bitposition (which is 0 for 'flag-essential')
to the flags, but the bit at the position.
---
 src/s6-rc/s6-rc-compile.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/s6-rc/s6-rc-compile.c b/src/s6-rc/s6-rc-compile.c
index 7aa37ea..c233f1a 100644
--- a/src/s6-rc/s6-rc-compile.c
+++ b/src/s6-rc/s6-rc-compile.c
@@ -368,7 +368,7 @@ static uint32_t read_flags (int dfd, char const *srcdir, char const *name)
       if (errno != ENOENT)
         strerr_diefu6sys(111, "read ", srcdir, "/", name, "/", files[i]) ;
     }
-    else flags |= i ;
+    else flags |= 1 << i ;
   }
   return flags ;
 }
-- 
2.20.1


             reply	other threads:[~2021-06-03 21:10 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-03 21:08 Christian Hohnstaedt [this message]
2021-06-03 22:10 ` Laurent Bercot

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210603210835.6111-1-christian@hohnstaedt.de \
    --to=christian@hohnstaedt.de \
    --cc=supervision@list.skarnet.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

supervision - discussion about system services, daemon supervision, init, runlevel management, and tools such as s6 and runit

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://inbox.vuxu.org/supervision

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V1 supervision supervision/ http://inbox.vuxu.org/supervision \
		subscribe@list.skarnet.org
	public-inbox-index supervision

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.vuxu.org/vuxu.archive.supervision.general


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git