summaryrefslogtreecommitdiff
path: root/safe.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-11-25 18:43:47 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-11-25 18:43:47 +0000
commitf77d40235275c80a4e1771b55a9d2c86bf129b26 (patch)
tree6209d8dbc2e49789b134c0ed21671b34b7b1728b /safe.c
parent5af1a10d7ce4e156e5587a25a0dd2cf88dd52a57 (diff)
safe.c: preserve encoding
* safe.c (rb_insecure_operation): preserve encoding of the called method name in error messages. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48570 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'safe.c')
-rw-r--r--safe.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/safe.c b/safe.c
index 7f3a412686..d790156c03 100644
--- a/safe.c
+++ b/safe.c
@@ -110,8 +110,8 @@ rb_insecure_operation(void)
{
ID caller_name = rb_frame_callee();
if (caller_name) {
- rb_raise(rb_eSecurityError, "Insecure operation - %s",
- rb_id2name(caller_name));
+ rb_raise(rb_eSecurityError, "Insecure operation - %"PRIsVALUE,
+ rb_id2str(caller_name));
}
else {
rb_raise(rb_eSecurityError, "Insecure operation: -r");