From: Brad King Date: Wed, 11 Jan 2012 13:15:09 +0000 (-0500) Subject: Declare mbstate_t and wcrtomb for Borland X-Git-Tag: v3.0.4~18 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d7e16a49c214faae1d8379e050c2e6d095aedcc4;p=thirdparty%2Flibarchive.git Declare mbstate_t and wcrtomb for Borland The Borland C++ 5.81 runtime library provides wcrtomb but only the C++ header actually declares the API. Since this is C code we cannot use the header, so declare it ourselves. SVN-Revision: 4126 --- diff --git a/libarchive/archive_windows.h b/libarchive/archive_windows.h index df62dce7c..8783291af 100644 --- a/libarchive/archive_windows.h +++ b/libarchive/archive_windows.h @@ -272,6 +272,10 @@ extern void __la_dosmaperr(unsigned long e); extern struct archive_entry *__la_win_entry_in_posix_pathseparator( struct archive_entry *); +#if defined(HAVE_WCRTOMB) && defined(__BORLANDC__) +typedef int mbstate_t; +size_t wcrtomb(char *, wchar_t, mbstate_t *); +#endif #if defined(_MSC_VER) && _MSC_VER < 1300 WINBASEAPI BOOL WINAPI GetVolumePathNameW(