aboutsummaryrefslogtreecommitdiffstats
path: root/string.c
diff options
context:
space:
mode:
Diffstat (limited to 'string.c')
-rw-r--r--string.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/string.c b/string.c
index 2dadbbb82e..d6c22dbfc4 100644
--- a/string.c
+++ b/string.c
@@ -3001,7 +3001,7 @@ rb_str_inspect(VALUE str)
escape_codepoint:
for (q = p-n; q < p; q++) {
s = buf;
- sprintf(buf, "\\x%02x", *q & 0377);
+ sprintf(buf, "\\x%02X", *q & 0377);
while (*s) {
str_cat_char(result, *s++, enc);
}
@@ -3113,7 +3113,7 @@ rb_str_dump(VALUE str)
}
else {
*q++ = '\\';
- sprintf(q, "x%02x", c&0xff);
+ sprintf(q, "x%02X", c&0xff);
q += 3;
}
}