[38918] in Kerberos

home help back first fref pref prev next nref lref last post

Re: Version 1.19.1 compilation issue - RedHat Linux

daemon@ATHENA.MIT.EDU (Greg Hudson)
Wed May 12 13:09:05 2021

To: Vipul Mehta <vipulmehta.1989@gmail.com>, <kerberos@mit.edu>
From: Greg Hudson <ghudson@mit.edu>
Message-ID: <fe1d919f-266d-50c9-7e59-93d9256dca7b@mit.edu>
Date: Wed, 12 May 2021 13:06:06 -0400
MIME-Version: 1.0
In-Reply-To: <CAMeQEL-_GJCMwM4A91HKKxoX18APdev2e4Ed6SvuMKy72pAfhg@mail.gmail.com>
Content-Language: en-US
Content-Type: text/plain; charset="utf-8"
Errors-To: kerberos-bounces@mit.edu
Content-Transfer-Encoding: 8bit

On 5/12/21 8:17 AM, Vipul Mehta wrote:
> Getting following error:
> gic_keytab.c:185: error: ‘etype_list’ may be used uninitialized in this
> function

This is a false positive (etype_list can only be used uninitialized if
k5_canonprinc() returns zero candidates without erroring out, and it
doesn't do that).  But I will likely add an initializer for etype_list
as I think the function is clearer that way.

In general I found that maybe-uninitialized warnings are almost always
false positives and depend a lot on the compiler version, which is why I
attempted to turn them off.  Apparently that's not possible in that
particular version of gcc, without also turning off errors for
-Wuninitialized (which are much less likely to be false positives).

> At top level:
> cc1: warning: unrecognized command line option "-Wno-maybe-uninitialized"

> In config.log, i can see that configure script is not able to identify that
> the option is not supported as gcc gives warning instead of error:

Interesting.  More recent versions of gcc seem to silently ignore
unrecognized -Wno- flags, while clang continues to print a warning
rather than error.

This is a minor problem, but having a working test for -Wno- options
would be an improvement.

> It compiles fine if i remove "error=uninitialized" to allow uninitialized
> variables.
> Is it safe to compile without it ?

Yes.

> What is the version of gcc used to build and test MIT Kerberos in dev
> environment ?

At the moment, gcc 7.5.0 in my dev environment, plus whatever version of
gcc is on the Github Actions runners.
________________________________________________
Kerberos mailing list           Kerberos@mit.edu
https://mailman.mit.edu/mailman/listinfo/kerberos


home help back first fref pref prev next nref lref last post