diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2020-08-29 07:38:45 +0900 |
|---|---|---|
| committer | Yukihiro "Matz" Matsumoto <[email protected]> | 2020-10-12 18:20:07 +0900 |
| commit | dd1ce5d53efa9a00cd9bdc7a7771bc6489da4469 (patch) | |
| tree | 1354054dcdf4f621c5adcbb8b5208fb079774957 /mrbgems/mruby-print | |
| parent | 7eaaee5405f71c598893e9a022c755f61f11e9ec (diff) | |
| download | mruby-dd1ce5d53efa9a00cd9bdc7a7771bc6489da4469.tar.gz mruby-dd1ce5d53efa9a00cd9bdc7a7771bc6489da4469.zip | |
Silence warnings from implicit integer conversions.
Caused from combination of `mrb_int`, `int` and `size_t`..
Diffstat (limited to 'mrbgems/mruby-print')
| -rw-r--r-- | mrbgems/mruby-print/src/print.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mrbgems/mruby-print/src/print.c b/mrbgems/mruby-print/src/print.c index df153d920..74d736397 100644 --- a/mrbgems/mruby-print/src/print.c +++ b/mrbgems/mruby-print/src/print.c @@ -22,7 +22,7 @@ printstr(mrb_state *mrb, const char *p, size_t len) #if defined(_WIN32) if (isatty(fileno(stdout))) { DWORD written; - int wlen = MultiByteToWideChar(CP_UTF8, 0, p, len, NULL, 0); + size_t wlen = MultiByteToWideChar(CP_UTF8, 0, p, len, NULL, 0); wchar_t* utf16 = (wchar_t*)mrb_malloc(mrb, (wlen+1) * sizeof(wchar_t)); if (MultiByteToWideChar(CP_UTF8, 0, p, len, utf16, wlen) > 0) { utf16[wlen] = 0; |
