libport: Move wine_utf8 functions back to libwine and make them obsolete.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
f4b7260d29
commit
473914f6a5
|
@ -88,8 +88,6 @@ extern int wine_cp_mbstowcs( const union cptable *table, int flags,
|
|||
extern int wine_cp_wcstombs( const union cptable *table, int flags,
|
||||
const WCHAR *src, int srclen,
|
||||
char *dst, int dstlen, const char *defchar, int *used );
|
||||
extern int wine_utf8_mbstowcs( int flags, const char *src, int srclen, WCHAR *dst, int dstlen );
|
||||
extern int wine_utf8_wcstombs( int flags, const WCHAR *src, int srclen, char *dst, int dstlen );
|
||||
|
||||
extern int strcmpiW( const WCHAR *str1, const WCHAR *str2 );
|
||||
extern int strncmpiW( const WCHAR *str1, const WCHAR *str2, int n );
|
||||
|
|
|
@ -102,6 +102,5 @@ C_SRCS = \
|
|||
stubs.c \
|
||||
symlink.c \
|
||||
usleep.c \
|
||||
utf8.c \
|
||||
wctomb.c \
|
||||
wctype.c
|
||||
|
|
|
@ -10,7 +10,8 @@ C_SRCS = \
|
|||
loader.c \
|
||||
mmap.c \
|
||||
port.c \
|
||||
sortkey.c
|
||||
sortkey.c \
|
||||
utf8.c
|
||||
|
||||
EXTRA_OBJS = version.o
|
||||
|
||||
|
|
|
@ -42,8 +42,6 @@ const void *libwine_port_functions[] =
|
|||
wine_cp_get_table,
|
||||
wine_cp_mbstowcs,
|
||||
wine_cp_wcstombs,
|
||||
wine_utf8_mbstowcs,
|
||||
wine_utf8_wcstombs
|
||||
};
|
||||
|
||||
/* no longer used, for backwards compatibility only */
|
||||
|
|
|
@ -20,6 +20,10 @@
|
|||
|
||||
#include <string.h>
|
||||
|
||||
#include "wine/asm.h"
|
||||
|
||||
#ifdef __ASM_OBSOLETE
|
||||
|
||||
#include "wine/unicode.h"
|
||||
|
||||
extern WCHAR wine_compose( const WCHAR *str ) DECLSPEC_HIDDEN;
|
||||
|
@ -95,7 +99,7 @@ static inline int get_length_wcs_utf8( int flags, const WCHAR *src, unsigned int
|
|||
|
||||
/* wide char to UTF-8 string conversion */
|
||||
/* return -1 on dst buffer overflow, -2 on invalid input char */
|
||||
int wine_utf8_wcstombs( int flags, const WCHAR *src, int srclen, char *dst, int dstlen )
|
||||
int wine_utf8_wcstombs_obsolete( int flags, const WCHAR *src, int srclen, char *dst, int dstlen )
|
||||
{
|
||||
int len;
|
||||
|
||||
|
@ -301,7 +305,7 @@ static inline int get_length_mbs_utf8( int flags, const char *src, int srclen )
|
|||
|
||||
/* UTF-8 to wide char string conversion */
|
||||
/* return -1 on dst buffer overflow, -2 on invalid input char */
|
||||
int wine_utf8_mbstowcs( int flags, const char *src, int srclen, WCHAR *dst, int dstlen )
|
||||
int wine_utf8_mbstowcs_obsolete( int flags, const char *src, int srclen, WCHAR *dst, int dstlen )
|
||||
{
|
||||
unsigned int res;
|
||||
const char *srcend = src + srclen;
|
||||
|
@ -336,3 +340,8 @@ int wine_utf8_mbstowcs( int flags, const char *src, int srclen, WCHAR *dst, int
|
|||
if (src < srcend) return -1; /* overflow */
|
||||
return dstlen - (dstend - dst);
|
||||
}
|
||||
|
||||
__ASM_OBSOLETE(wine_utf8_wcstombs);
|
||||
__ASM_OBSOLETE(wine_utf8_mbstowcs);
|
||||
|
||||
#endif /* __ASM_OBSOLETE */
|
|
@ -53,8 +53,6 @@ WINE_1.0
|
|||
wine_mmap_remove_reserved_area;
|
||||
wine_set_fs;
|
||||
wine_set_gs;
|
||||
wine_utf8_mbstowcs;
|
||||
wine_utf8_wcstombs;
|
||||
wine_wctype_table;
|
||||
|
||||
/* the following functions are obsolete and only exported for backwards compatibility */
|
||||
|
@ -120,6 +118,8 @@ WINE_1.0
|
|||
wine_pthread_get_functions;
|
||||
wine_pthread_set_functions;
|
||||
wine_switch_to_stack;
|
||||
wine_utf8_mbstowcs;
|
||||
wine_utf8_wcstombs;
|
||||
|
||||
local: *;
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue