]> git.eshelyaron.com Git - emacs.git/commitdiff
Ignore -fanalyzer-null-argument in pgtkterm.c
authorPaul Eggert <eggert@cs.ucla.edu>
Mon, 27 Jan 2025 06:15:49 +0000 (22:15 -0800)
committerEshel Yaron <me@eshelyaron.com>
Thu, 30 Jan 2025 18:07:10 +0000 (19:07 +0100)
* src/pgtkterm.c: Ignore -Wanalyzer-null-dereference.
I don’t have time to look into all the diagnostics,
but the ones I checked seemed to be false alarms with
gcc -std=gnu23 on x86-64, and we are ignoring this
diagnostic in other modules.  This is GCC 14.2.1
20250110 (Red Hat 14.2.1-7).

(cherry picked from commit 8d8272d02e38ee3624cd3f16767f3c60fb3383ea)

src/pgtkterm.c

index 1d679f0cf57987c058b503ded5463536a0933f1a..1f468300debee087f66d341be6a0ff4f8a9e2b08 100644 (file)
@@ -22,6 +22,11 @@ along with GNU Emacs.  If not, see <https://www.gnu.org/licenses/>.  */
    interpretation of even the system includes. */
 #include <config.h>
 
+/* Work around GCC bug 102671.  */
+#if 10 <= __GNUC__
+# pragma GCC diagnostic ignored "-Wanalyzer-null-dereference"
+#endif
+
 #include <cairo.h>
 #include <fcntl.h>
 #include <math.h>