From: Simon Quigley <tsimonq2@ubuntu.com>, Simon Josefsson <simon@josefsson.org>
Subject: Fix FTBFS with later versions of MySQL which replace my_bool with the standard C bool.
Bug: https://savannah.nongnu.org/support/index.php?111301
Last-Update: 2025-08-16
Forwarded: yes

diff --git a/src/mysql.c b/src/mysql.c
index b6593be..0b3073e 100644
--- a/src/mysql.c
+++ b/src/mysql.c
@@ -24,6 +24,7 @@
 #include "nss_mysql.h"
 #include <string.h>             /* strlen() */
 #include <netinet/in.h>         /* struct sockaddr_in */
+#include <stdbool.h>
 
 con_info_t ci = { nfalse };
 extern conf_t conf;
@@ -132,7 +133,7 @@ _nss_mysql_set_options (sql_server_t *server)
 {
   DN ("_nss_mysql_set_options");
   const unsigned int def_timeout = DEF_TIMEOUT;
-  const my_bool reconnect = 1;
+  const bool reconnect = 1;
 
   DENTER;
 
@@ -192,7 +193,7 @@ _nss_mysql_connect_sql (MYSQL_RES **mresult)
   int retval;
   sql_server_t *server = &conf.sql.server;
   unsigned int port;
-  const my_bool noreconnect = 0;
+  const bool noreconnect = 0;
 
   DENTER;
 
