From 13e47e81d99944df1bc932b050524d787d0a1391 Mon Sep 17 00:00:00 2001 From: nobu Date: Sun, 12 Jan 2014 08:11:32 +0000 Subject: tcltklib.c: create_ip_exc format argument * ext/tk/tcltklib.c (create_ip_exc): format argument must not be a dynamic string, not to contain unescaped %. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44570 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ext/tk/tcltklib.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'ext/tk') diff --git a/ext/tk/tcltklib.c b/ext/tk/tcltklib.c index d269f9c43e..6f9aa9046b 100644 --- a/ext/tk/tcltklib.c +++ b/ext/tk/tcltklib.c @@ -6628,7 +6628,7 @@ ip_make_safe_core(interp, argc, argv) if (Tcl_MakeSafe(ptr->ip) == TCL_ERROR) { /* return rb_exc_new2(rb_eRuntimeError, Tcl_GetStringResult(ptr->ip)); */ - return create_ip_exc(interp, rb_eRuntimeError, + return create_ip_exc(interp, rb_eRuntimeError, "%s", Tcl_GetStringResult(ptr->ip)); } @@ -9293,7 +9293,7 @@ ip_get_variable2_core(interp, argc, argv) volatile VALUE exc; /* exc = rb_exc_new2(rb_eRuntimeError, Tcl_GetStringResult(ptr->ip)); */ - exc = create_ip_exc(interp, rb_eRuntimeError, + exc = create_ip_exc(interp, rb_eRuntimeError, "%s", Tcl_GetStringResult(ptr->ip)); /* Tcl_Release(ptr->ip); */ rbtk_release_ip(ptr); @@ -9432,7 +9432,7 @@ ip_set_variable2_core(interp, argc, argv) volatile VALUE exc; /* exc = rb_exc_new2(rb_eRuntimeError, Tcl_GetStringResult(ptr->ip)); */ - exc = create_ip_exc(interp, rb_eRuntimeError, + exc = create_ip_exc(interp, rb_eRuntimeError, "%s", Tcl_GetStringResult(ptr->ip)); /* Tcl_Release(ptr->ip); */ rbtk_release_ip(ptr); @@ -9552,7 +9552,7 @@ ip_unset_variable2_core(interp, argc, argv) if (FIX2INT(flag) & TCL_LEAVE_ERR_MSG) { /* return rb_exc_new2(rb_eRuntimeError, Tcl_GetStringResult(ptr->ip)); */ - return create_ip_exc(interp, rb_eRuntimeError, + return create_ip_exc(interp, rb_eRuntimeError, "%s", Tcl_GetStringResult(ptr->ip)); } return Qfalse; -- cgit v1.2.3