File 9352-Ensure-backwards-compatibility.patch of Package erlang

From 61fae0023846958e7c7bb884fec7cd0871f067bc Mon Sep 17 00:00:00 2001
From: Maria Scott <67057258+Maria-12648430@users.noreply.github.com>
Date: Wed, 4 Mar 2026 14:44:19 +0100
Subject: [PATCH 2/3] Ensure backwards compatibility
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Co-authored-by: Björn Gustavsson <bgustavsson@gmail.com>
---
 lib/stdlib/src/sys.erl | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/stdlib/src/sys.erl b/lib/stdlib/src/sys.erl
index 9220045186..4a39a39c0f 100644
--- a/lib/stdlib/src/sys.erl
+++ b/lib/stdlib/src/sys.erl
@@ -1078,7 +1078,8 @@ do_change_code(Mod, Module, Vsn, Extra, Misc) ->
         Else -> {{error, Else}, Misc}
     catch
         throw:{ok, _} = Res -> Res;
-        _:Else -> {{error, Else}, Misc}
+        error:Reason:Stack -> {{error, {'EXIT', {Reason, Stack}}}, Misc};
+        exit:Exit -> {{error, {'EXIT', Exit}}, Misc}
     end.
 
 print_event(X) -> print_event(standard_io, X).
-- 
2.51.0

openSUSE Build Service is sponsored by