OpenAFS Master Repository branch, openafs-stable-1_8_x, updated. openafs-stable-1_8_8_1-65-gf6e6ed4

Gerrit Code Review gerrit@openafs.org
Thu, 4 Aug 2022 14:09:09 -0400


The following commit has been merged in the openafs-stable-1_8_x branch:
commit f6e6ed4b316378031676d7180b9e71336a3c9f62
Author: Cheyenne Wills <cwills@sinenomine.net>
Date:   Tue Jun 7 11:14:55 2022 -0600

    lwp: Ignore dangling-pointer warning in process.c
    
    In lwp/process.c the address of a stack variable is saved as part of
    creating a new context.  GCC-12 is flagging the statement with a
    diagnostic:
    
      ./process.c:46:24: error: storing the address of local variable
          ‘stackvar’ in ‘*savearea.topstack’ [-Werror=dangling-pointer=]
       46 |     savearea->topstack = (char *)&stackvar;
          |     ~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
    
    In this particular case, the code is meaning to save the address of the
    stack in preparation of setting up a new context, which requires knowing
    the address the current stack.
    
    The diagnostic is changed from a warning to an error when configured
    with --enable-checking.
    
    Set the env variable CFLAGS_NODANGLING_POINTER to
    '-Wno-dangling-pointer' if the compiler supports the option and update
    the src/lwp/Makefile.in to use the flag when compiling process.c
    
    Reviewed-on: https://gerrit.openafs.org/14957
    Reviewed-by: Andrew Deason <adeason@sinenomine.net>
    Reviewed-by: Michael Meffie <mmeffie@sinenomine.net>
    Tested-by: BuildBot <buildbot@rampaginggeek.com>
    Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
    (cherry picked from commit 748ae0fc25c51316d741afd9b9dfd479ffdf3250)
    
    Change-Id: I03d2d4a77b4a391f023f40e9793968e03a50c241
    Reviewed-on: https://gerrit.openafs.org/15062
    Tested-by: BuildBot <buildbot@rampaginggeek.com>
    Reviewed-by: Andrew Deason <adeason@sinenomine.net>
    Reviewed-by: Michael Meffie <mmeffie@sinenomine.net>
    Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de>

 CODING              | 4 +++-
 src/cf/osconf.m4    | 4 ++++
 src/lwp/Makefile.in | 1 +
 3 files changed, 8 insertions(+), 1 deletion(-)

-- 
OpenAFS Master Repository