Source: https://salsa.debian.org/gnome-team/libgda5/-/blob/debian/aa0d43f078ecb157e6186f8584ff355a64ba2d7a/debian/patches/gcc-14-compat-1075169.patch

From: "Rebecca N. Palmer" <rebecca_palmer@zoho.com>
Date: Sat, 7 Dec 2024 19:32:15 +0000
Subject: Allow building with gcc-14

Closes: #1075169

Origin: upstream 7abf8273 by Daniel Espinosa Ortiz
 and 7d9229b6 by Pavlo Solntsev
---
 libgda-xslt/sql_backend.c | 4 ++--
 libgda/gda-connection.c   | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/libgda-xslt/sql_backend.c b/libgda-xslt/sql_backend.c
index 39602ce..f3dda85 100644
--- a/libgda-xslt/sql_backend.c
+++ b/libgda-xslt/sql_backend.c
@@ -146,8 +146,8 @@ _gda_xslt_bk_section (GdaXsltExCont * exec, GdaXsltIntCont * pdata,
 		     cur_node = cur_node->next) {
 			if (IS_XSLT_ELEM (cur_node)) {
 				if (IS_XSLT_NAME (cur_node, "call-template")) {
-					xsltStylePreCompPtr info =
-						(xsltStylePreCompPtr)
+					xsltElemPreCompPtr info =
+						(xsltElemPreCompPtr)
 						cur_node->psvi;
 					if (info != NULL) {
 						xsltCallTemplate
diff --git a/libgda/gda-connection.c b/libgda/gda-connection.c
index 43911e9..71c7dde 100644
--- a/libgda/gda-connection.c
+++ b/libgda/gda-connection.c
@@ -6458,7 +6458,7 @@ gda_connection_add_prepared_statement (GdaConnection *cnc, GdaStatement *gda_stm
 
 	if (!cnc->priv->prepared_stmts)
 		cnc->priv->prepared_stmts = g_hash_table_new_full (g_direct_hash, g_direct_equal,
-								   NULL, _gda_prepared_estatement_free);
+								   NULL, (GDestroyNotify) _gda_prepared_estatement_free);
 	g_hash_table_remove (cnc->priv->prepared_stmts, gda_stmt);
 	PreparedStatementRef *ref = _gda_prepared_estatement_new (gda_stmt, prepared_stmt);
 	g_hash_table_insert (cnc->priv->prepared_stmts, gda_stmt, ref);
