Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-38861

glibc: Disable type-based based aliasing for sockaddr structs [rhel-9]

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Normal Normal
    • None
    • rhel-9.5
    • glibc
    • None
    • None
    • Patch
    • sst_pt_libraries
    • ssg_platform_tools
    • 1
    • None
    • Red Hat Enterprise Linux
    • None
    • None
    • None
    • All
    • None

      Upstream in glibc, we fixed a code generation issue with later GCC versions which break certain common coding patterns involving socket addresses. We should consider backporting this commit:

      commit 8d7b6b4cb27d4dec1dd5f7960298c1699275f962
      Author: Florian Weimer <fweimer@redhat.com>
      Date:   Sat May 18 09:33:19 2024 +0200
      
          socket: Use may_alias on sockaddr structs (bug 19622)
          
          This supports common coding patterns.  The GCC C front end before
          version 7 rejects the may_alias attribute on a struct definition
          if it was not present in a previous forward declaration, so this
          attribute can only be conditionally applied.
          
          This implements the spirit of the change in Austin Group issue 1641.
          
          Suggested-by: Marek Polacek <polacek@redhat.com>
          Suggested-by: Jakub Jelinek <jakub@redhat.com>
          Reviewed-by: Sam James <sam@gentoo.org>
          Reviewed-by: Carlos O'Donell <carlos@redhat.com>
      

      GCC 11 should benefit from this, too, and GCC Toolset even more so.

            glibc-bugzilla Platform Tools - Libraries Bot
            fweimer@redhat.com Florian Weimer
            Platform Tools - Libraries Bot Platform Tools - Libraries Bot
            qe-baseos-tools-bugs@redhat.com qe-baseos-tools-bugs@redhat.com qe-baseos-tools-bugs@redhat.com qe-baseos-tools-bugs@redhat.com
            Votes:
            0 Vote for this issue
            Watchers:
            9 Start watching this issue

              Created:
              Updated: