From 4b65d5638c607747e2f5b28ed1914e3c397b4097 Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Tue, 30 May 2023 18:36:20 +0200 Subject: [PATCH] gh-80064: Fix is_valid_wide_char() return type (#105099) Return a classical int, rather than size_t. The size_t type was kept from copied/pasted code related to mbstowcs(). --- Python/fileutils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Python/fileutils.c b/Python/fileutils.c index f137ee93650..f262c3e095c 100644 --- a/Python/fileutils.c +++ b/Python/fileutils.c @@ -112,7 +112,7 @@ _Py_device_encoding(int fd) } -static size_t +static int is_valid_wide_char(wchar_t ch) { #ifdef HAVE_NON_UNICODE_WCHAR_T_REPRESENTATION