From: Mick <michaelkintzios@gmail.com>
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] profile-sync-daemon "bad substitution" at boot
Date: Thu, 06 Sep 2018 09:27:17 +0100 [thread overview]
Message-ID: <2590696.IllPHginTI@dell_xps> (raw)
In-Reply-To: <CAJ1xhMW+WSNU8ohy5BS9o8TZ5WcfjZra8W-Qc5WVdwYNe13Yvw@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1804 bytes --]
On Thursday, 6 September 2018 09:22:35 BST Alexander Kapshuk wrote:
> On Thu, Sep 6, 2018 at 11:18 AM Alexander Kapshuk
>
> <alexander.kapshuk@gmail.com> wrote:
> > On Thu, Sep 6, 2018 at 10:48 AM Samuraiii <samurai.no.dojo@gmail.com>
wrote:
> > > On 5.9.2018 21:20, Mick wrote:
> > >
> > > Hi All,
> > >
> > > I just noticed a psd error at boot time:
> > >
> > > /usr/bin/profile-sync-daemon: line 325: ${#DIRArr[@]##*/}: bad
> > > substitution
> > >
> > > Any idea what's brought this about?
> > >
> > > Hi,
> > >
> > > my bet is that your /bin/sh != /bin/bash and
> > > /usr/bin/profile-sync-daemon starts with #!/bin/sh.
> > >
> > > The other way around /usr/bin/profile-sync-daemon contains bashishms.
> > >
> > > You can try (as a test) to change #!/bin/sh for #!/bin/bash...
> > >
> > > S
> >
> > The shebang in the master repository is '#!/bin/bash'.
> > https://raw.githubusercontent.com/graysky2/profile-sync-daemon/master/comm
> > on/profile-sync-daemon.in
> >
> > The error message is a shell parameter expansion syntax error, which
> > comprises two different expansion constructs referenced below.
> > ${#parameter}
> > String Length.
> >
> > ${parameter##[word]}
> > Remove Largest Prefix Pattern.
> >
> > See section 2.6.2 Parameter Expansion,
> > http://pubs.opengroup.org/onlinepubs/9699919799/nframe.html.
> >
> > The script in the master repository referenced above does not contain
> > the line in question. It has '${#DIRArr[@]/}' and '${DIRArr[@]##*/}'.
>
> This appears to have been reported as a bug in Debian [1]
> [1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=839049
> And applied upstream [2].
> https://github.com/graysky2/profile-sync-daemon/pull/185/files/654f5359abfe7
> aab2e1616dd74c8ba0f76ce4ab4
Thanks Alexander, good catch!
--
Regards,
Mick
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2018-09-06 8:27 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-05 19:20 [gentoo-user] profile-sync-daemon "bad substitution" at boot Mick
2018-09-06 7:48 ` Samuraiii
2018-09-06 8:18 ` Alexander Kapshuk
2018-09-06 8:22 ` Alexander Kapshuk
2018-09-06 8:27 ` Mick [this message]
2018-09-06 8:22 ` Mick
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=2590696.IllPHginTI@dell_xps \
--to=michaelkintzios@gmail.com \
--cc=gentoo-user@lists.gentoo.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