summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2025-11-08 13:20:01 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2025-11-08 20:51:04 +0900
commit3a5e7e9580fd8cea5f9b53dda377e61faeebe621 (patch)
treeebfc651e0a0c00a28bbd5d9195933c4244744424
parentaacd9f206a57375df38e1b2552da37a68d77e1e1 (diff)
Constify
-rw-r--r--box.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/box.c b/box.c
index bdb80a788c..0ea7418284 100644
--- a/box.c
+++ b/box.c
@@ -509,7 +509,7 @@ copy_ext_file_error(char *message, size_t size)
}
#else
static const char *
-copy_ext_file_error(char *message, size_t size, int copy_retvalue, char *src_path, char *dst_path)
+copy_ext_file_error(char *message, size_t size, int copy_retvalue, const char *src_path, const char *dst_path)
{
switch (copy_retvalue) {
case 1:
@@ -532,7 +532,7 @@ copy_ext_file_error(char *message, size_t size, int copy_retvalue, char *src_pat
#endif
static int
-copy_ext_file(char *src_path, char *dst_path)
+copy_ext_file(const char *src_path, const char *dst_path)
{
#if defined(_WIN32)
int rvalue;
@@ -664,7 +664,7 @@ rb_box_local_extension(VALUE box_value, VALUE fname, VALUE path)
{
char ext_path[MAXPATHLEN], fname2[MAXPATHLEN], basename[MAXPATHLEN];
int copy_error, wrote;
- char *src_path = RSTRING_PTR(path), *fname_ptr = RSTRING_PTR(fname);
+ const char *src_path = RSTRING_PTR(path), *fname_ptr = RSTRING_PTR(fname);
rb_box_t *box = rb_get_box_t(box_value);
fname_without_suffix(fname_ptr, fname2, sizeof(fname2));