msvcrt: Get rid of the now unused strndup/wstrndup functions.

This commit is contained in:
Alexandre Julliard 2007-07-27 12:18:44 +02:00
parent 00c81e9d9f
commit 1f5a4a8046
3 changed files with 0 additions and 36 deletions

View File

@ -115,8 +115,6 @@ extern thread_data_t *msvcrt_get_thread_data(void);
extern int MSVCRT___lc_codepage; extern int MSVCRT___lc_codepage;
void msvcrt_set_errno(int); void msvcrt_set_errno(int);
char* msvcrt_strndup(const char*,unsigned int);
MSVCRT_wchar_t *msvcrt_wstrndup(const MSVCRT_wchar_t*, unsigned int);
void _purecall(void); void _purecall(void);
void _amsg_exit(int errnum); void _amsg_exit(int errnum);

View File

@ -30,23 +30,6 @@
WINE_DEFAULT_DEBUG_CHANNEL(msvcrt); WINE_DEFAULT_DEBUG_CHANNEL(msvcrt);
/* INTERNAL: MSVCRT_malloc() based strndup */
char* msvcrt_strndup(const char* buf, unsigned int size)
{
char* ret;
unsigned int len = strlen(buf), max_len;
max_len = size <= len? size : len + 1;
ret = MSVCRT_malloc(max_len);
if (ret)
{
memcpy(ret,buf,max_len);
ret[max_len] = 0;
}
return ret;
}
/********************************************************************* /*********************************************************************
* _mbsdup (MSVCRT.@) * _mbsdup (MSVCRT.@)
* _strdup (MSVCRT.@) * _strdup (MSVCRT.@)

View File

@ -30,23 +30,6 @@
WINE_DEFAULT_DEBUG_CHANNEL(msvcrt); WINE_DEFAULT_DEBUG_CHANNEL(msvcrt);
/* INTERNAL: MSVCRT_malloc() based wstrndup */
MSVCRT_wchar_t* msvcrt_wstrndup(const MSVCRT_wchar_t *buf, unsigned int size)
{
MSVCRT_wchar_t* ret;
unsigned int len = strlenW(buf), max_len;
max_len = size <= len? size : len + 1;
ret = MSVCRT_malloc(max_len * sizeof (MSVCRT_wchar_t));
if (ret)
{
memcpy(ret,buf,max_len * sizeof (MSVCRT_wchar_t));
ret[max_len] = 0;
}
return ret;
}
/********************************************************************* /*********************************************************************
* _wcsdup (MSVCRT.@) * _wcsdup (MSVCRT.@)
*/ */