summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
Diffstat (limited to 'ext')
-rw-r--r--ext/objspace/objspace_dump.c4
-rw-r--r--ext/socket/raddrinfo.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/ext/objspace/objspace_dump.c b/ext/objspace/objspace_dump.c
index 47aaaf2e3a5..0dd3a9e79cf 100644
--- a/ext/objspace/objspace_dump.c
+++ b/ext/objspace/objspace_dump.c
@@ -182,7 +182,7 @@ dump_append_string_content(struct dump_config *dc, VALUE obj)
{
dump_append(dc, ", \"bytesize\":%ld", RSTRING_LEN(obj));
if (!STR_EMBED_P(obj) && !STR_SHARED_P(obj) && (long)rb_str_capacity(obj) != RSTRING_LEN(obj))
- dump_append(dc, ", \"capacity\":%"PRIdSIZE, rb_str_capacity(obj));
+ dump_append(dc, ", \"capacity\":%"PRIuSIZE, rb_str_capacity(obj));
if (is_ascii_string(obj)) {
dump_append(dc, ", \"value\":");
@@ -248,7 +248,7 @@ dump_object(VALUE obj, struct dump_config *dc, int part)
break;
case T_HASH:
- dump_append(dc, ", \"size\":%"PRIdSIZE, (size_t)RHASH_SIZE(obj));
+ dump_append(dc, ", \"size\":%"PRIuSIZE, (size_t)RHASH_SIZE(obj));
if (FL_TEST(obj, HASH_PROC_DEFAULT))
dump_append(dc, ", \"default\":\"%p\"", (void *)RHASH_IFNONE(obj));
break;
diff --git a/ext/socket/raddrinfo.c b/ext/socket/raddrinfo.c
index 11f5d1f5a69..67bc9c2a97d 100644
--- a/ext/socket/raddrinfo.c
+++ b/ext/socket/raddrinfo.c
@@ -462,7 +462,7 @@ host_str(VALUE host, char *hbuf, size_t hbuflen, int *flags_ptr)
if (flags_ptr) *flags_ptr |= AI_NUMERICHOST;
}
else if (len >= hbuflen) {
- rb_raise(rb_eArgError, "hostname too long (%"PRIdSIZE")",
+ rb_raise(rb_eArgError, "hostname too long (%"PRIuSIZE")",
len);
}
else {
@@ -493,7 +493,7 @@ port_str(VALUE port, char *pbuf, size_t pbuflen, int *flags_ptr)
SafeStringValueCStr(port);
RSTRING_GETMEM(port, serv, len);
if (len >= pbuflen) {
- rb_raise(rb_eArgError, "service name too long (%"PRIdSIZE")",
+ rb_raise(rb_eArgError, "service name too long (%"PRIuSIZE")",
len);
}
memcpy(pbuf, serv, len);