lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 13 Jul 2021 07:43:42 -0400 (EDT)
From:   Mikulas Patocka <mpatocka@...hat.com>
To:     Nico Schottelius <nico.schottelius@...leich.ch>
cc:     Nico Schottelius <nico-linuxsetlocalversion@...ottelius.org>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Masahiro Yamada <masahiroy@...nel.org>,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3] scripts/setlocalversion: fix a bug when LOCALVERSION
 is empty



On Tue, 13 Jul 2021, Nico Schottelius wrote:

> 
> 
> Mikulas Patocka <mpatocka@...hat.com> writes:
> > I set LOCALVERSION to an empty string (with "export LOCALVERSION="). This
> > prevented the kernel from adding a "+" sign to the kernel version. Since
> > the commit 042da426f8eb, it no longer works and the kernel adds a "+" sign
> > if LOCALVERSION is set and empty.
> >
> > If you don't like "if [ "${LOCALVERSION+set}" != "set" ]", then please
> > provide some other way how to test if the variable is set.
> 
> I fail to see the problem you are solving, as that case works exactly
> like I wrote in my last mail:

The problem is this - I have a few patches applied to the kernel and I 
don't want the plus sign in the kernel version. So, I set
"export LOCALVERSION=". In the kernel 5.13 and previous versions, there is 
no plus sign at the end of version string. With the version 5.14-rc1, 
there is a plus sign.because of the patch 042da426f8eb.

> [11:09:03] nb3:~$ export LOCALVERSION=; [ -z "${LOCALVERSION}" ] && echo unset
> unset
> [11:09:27] nb3:~$ echo $BASH_VERSION
> 5.1.8(1)-release
> 
> Did you try that in your environment?

I tried and it and it doesn't work - the plus sign is present in the 
kernel version because [ -z "${LOCALVERSION}" ] return true.

Mikulas

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ