1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-21 18:25:41 +03:00
aports/community/libmarisa/format-sec.patch
2023-02-01 09:45:55 +01:00

23 lines
1 KiB
Diff

Patch-Source: https://github.com/archlinux/svntogit-community/blob/packages/marisa/trunk/fix-format-security.patch
From 5813d3b189512202b698aa4851e21b382acd003b Mon Sep 17 00:00:00 2001
From: Xeonacid <h.dwwwwww@gmail.com>
Date: Sat, 5 Feb 2022 08:51:43 +0800
Subject: [PATCH] Fix format security
---
bindings/ruby/marisa-swig_wrap.cxx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/bindings/ruby/marisa-swig_wrap.cxx b/bindings/ruby/marisa-swig_wrap.cxx
index eae2304..ddc346d 100644
--- a/bindings/ruby/marisa-swig_wrap.cxx
+++ b/bindings/ruby/marisa-swig_wrap.cxx
@@ -1402,7 +1402,7 @@ SWIG_Ruby_AppendOutput(VALUE target, VALUE o) {
/* Error manipulation */
#define SWIG_ErrorType(code) SWIG_Ruby_ErrorType(code)
-#define SWIG_Error(code, msg) rb_raise(SWIG_Ruby_ErrorType(code), msg)
+#define SWIG_Error(code, msg) rb_raise(SWIG_Ruby_ErrorType(code), "%s", msg)
#define SWIG_fail goto fail