public inbox for cygwin-cvs@sourceware.org
help / color / mirror / Atom feed
* [newlib-cygwin/main] Cygwin: mbrtowi: fix return type
@ 2023-02-14 19:29 Corinna Vinschen
  0 siblings, 0 replies; only message in thread
From: Corinna Vinschen @ 2023-02-14 19:29 UTC (permalink / raw)
  To: cygwin-cvs

https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=1fc35f30bdc67592150592ea78f808d44c913faf

commit 1fc35f30bdc67592150592ea78f808d44c913faf
Author:     Corinna Vinschen <corinna@vinschen.de>
AuthorDate: Tue Feb 14 20:18:42 2023 +0100
Commit:     Corinna Vinschen <corinna@vinschen.de>
CommitDate: Tue Feb 14 20:18:42 2023 +0100

    Cygwin: mbrtowi: fix return type
    
    bad typo: change wint_t to size_t
    
    Signed-off-by: Corinna Vinschen <corinna@vinschen.de>

Diff:
---
 winsup/cygwin/local_includes/wchar.h | 2 +-
 winsup/cygwin/strfuncs.cc            | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/winsup/cygwin/local_includes/wchar.h b/winsup/cygwin/local_includes/wchar.h
index 3d746c29b9bf..10b44791c505 100644
--- a/winsup/cygwin/local_includes/wchar.h
+++ b/winsup/cygwin/local_includes/wchar.h
@@ -41,7 +41,7 @@ extern wctomb_f __utf8_wctomb;
 
 /* replacement function for mbrtowc, returning a wint_t representing
    a UTF-32 value. Defined in strfuncs.cc */
-extern wint_t mbrtowi (wint_t *, const char *, size_t, mbstate_t *);
+extern size_t mbrtowi (wint_t *, const char *, size_t, mbstate_t *);
 
 #ifdef __cplusplus
 }
diff --git a/winsup/cygwin/strfuncs.cc b/winsup/cygwin/strfuncs.cc
index 0b9d8ac1f639..d62179a1de06 100644
--- a/winsup/cygwin/strfuncs.cc
+++ b/winsup/cygwin/strfuncs.cc
@@ -114,7 +114,7 @@ transform_chars_af_unix (PWCHAR out, const char *path, __socklen_t len)
 
 /* replacement function for mbrtowc, returning a wint_t representing
    a UTF-32 value. */
-extern "C" wint_t
+extern "C" size_t
 mbrtowi (wint_t *pwi, const char *s, size_t n, mbstate_t *ps)
 {
   size_t len, len2;

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-02-14 19:29 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-14 19:29 [newlib-cygwin/main] Cygwin: mbrtowi: fix return type Corinna Vinschen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).