File firebird-CVE-2025-54989.patch of Package firebird.40363

From dd0fa8bc14ad059609370b3461a47963edce95b8 Mon Sep 17 00:00:00 2001
From: Jonathan Kang <jonathankang@gnome.org>
Date: Wed, 20 Aug 2025 09:45:16 +0800
Subject: [PATCH] Fix for GHSA-7qp6-hqxj-pjjp / ZDI-CAN-26486

---
 src/remote/protocol.cpp | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/src/remote/protocol.cpp b/src/remote/protocol.cpp
index 9bbe37a7e0..04f1c2fc79 100644
--- a/src/remote/protocol.cpp
+++ b/src/remote/protocol.cpp
@@ -1834,6 +1834,11 @@ static bool_t xdr_trrq_message( XDR* xdrs, USHORT msg_type)
 	rem_port* port = (rem_port*) xdrs->x_public;
 	Rpr* procedure = port->port_rpr;
 
+	// normally that never happens
+	fb_assert(procedure);
+	if (!procedure)
+		return false;
+
 	if (msg_type == 1)
 		return xdr_message(xdrs, procedure->rpr_out_msg, procedure->rpr_out_format);
 
-- 
2.49.0

openSUSE Build Service is sponsored by