Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] support/mkusers: fix warnings when adding a new user
Date: Sat, 5 Apr 2014 18:39:32 +0200	[thread overview]
Message-ID: <20140405183932.6fdb1b07@skate> (raw)
In-Reply-To: <1396715083-20764-1-git-send-email-yann.morin.1998@free.fr>

Dear Yann E. MORIN,

On Sat,  5 Apr 2014 18:24:43 +0200, Yann E. MORIN wrote:
> From: "Yann E. MORIN" <yann.morin.1998@free.fr>
> 
> When adding a new user (or a new group), we would get warnings, like:
>   [...]/support/scripts/mkusers: line 145: [: too many arguments
> 
> This is because we're checking if a UID (or a GID) is already defined,
> and/or is different from the requested one, both checks in the same
> test.
> 
> Of course, if a UID (or a GID) is not defined, it does not have a value,
> so we can not compare it to an integer.
> 
> Fix that by splitting the test in two, so the second is only executed if
> the first is sucessful.
> 
> Reported-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
> Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
> ---
>  support/scripts/mkusers | 12 +++++++++---
>  1 file changed, 9 insertions(+), 3 deletions(-)

Applied, thanks.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

      reply	other threads:[~2014-04-05 16:39 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-05 16:24 [Buildroot] [PATCH] support/mkusers: fix warnings when adding a new user Yann E. MORIN
2014-04-05 16:39 ` Thomas Petazzoni [this message]

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=20140405183932.6fdb1b07@skate \
    --to=thomas.petazzoni@free-electrons.com \
    --cc=buildroot@busybox.net \
    /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