[前][次][番号順一覧][スレッド一覧]

ruby-changes:70417

From: Kazuhiro <ko1@a...>
Date: Tue, 21 Dec 2021 18:21:24 +0900 (JST)
Subject: [ruby-changes:70417] 48a0905d25 (master): Add missing '%' in format string

https://git.ruby-lang.org/ruby.git/commit/?id=48a0905d25

From 48a0905d25654d2f949ce870a144d8248ccdcf0d Mon Sep 17 00:00:00 2001
From: Kazuhiro NISHIYAMA <zn@m...>
Date: Tue, 21 Dec 2021 18:20:21 +0900
Subject: Add missing '%' in format string

---
 hash.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hash.c b/hash.c
index 07ec93d7840..f788375a7e9 100644
--- a/hash.c
+++ b/hash.c
@@ -5242,7 +5242,7 @@ ruby_setenv(const char *name, const char *value) https://github.com/ruby/ruby/blob/trunk/hash.c#L5242
         mem_size = len + strlen(value) + 2;
         mem_ptr = malloc(mem_size);
         if (mem_ptr == NULL)
-            rb_sys_fail_str(rb_sprintf("malloc("PRIuSIZE")", mem_size));
+            rb_sys_fail_str(rb_sprintf("malloc(%"PRIuSIZE")", mem_size));
         snprintf(mem_ptr, mem_size, "%s=%s", name, value);
     }
 
-- 
cgit v1.2.1


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]