| Server IP : 209.209.40.120 / Your IP : 216.73.217.112 Web Server : Microsoft-IIS/10.0 System : Windows NT NEWWWW 10.0 build 17763 (Windows Server 2019) i586 User : NEWWWW$ ( 0) PHP Version : 8.3.30 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : C:/Program Files (x86)/Windows Kits/10/Source/10.0.19041.0/ucrt/mbstring/ |
Upload File : |
/***
*mbsinc.c - Move MBCS string pointer ahead one charcter.
*
* Copyright (c) Microsoft Corporation. All rights reserved.
*
*Purpose:
* Move MBCS string pointer ahead one character.
*
*******************************************************************************/
#ifndef _MBCS
#error This file should only be compiled with _MBCS defined
#endif
#include <corecrt_internal.h>
#include <corecrt_internal_mbstring.h>
#include <stddef.h>
#pragma warning(disable:__WARNING_POTENTIAL_BUFFER_OVERFLOW_NULLTERMINATED) // 26018
/***
*_mbsinc - Move MBCS string pointer ahead one charcter.
*
*Purpose:
* Move the supplied string pointer ahead by one
* character. MBCS characters are handled correctly.
*
*Entry:
* const unsigned char *current = current char pointer (legal MBCS boundary)
*
*Exit:
* Returns pointer after moving it.
*
*Exceptions:
* Input parameters are validated. Refer to the validation section of the function.
*
*******************************************************************************/
extern "C" unsigned char * __cdecl _mbsinc_l(
const unsigned char *current,
_locale_t plocinfo
)
{
if ( (_ismbblead_l)(*(current++),plocinfo))
{
/* don't move forward two if we get leadbyte, EOS
also don't assert here as we are too low level
*/
if(*current!='\0')
{
current++;
}
}
return (unsigned char *)current;
}
extern "C" unsigned char * (__cdecl _mbsinc)(
const unsigned char *current
)
{
/* validation section */
_VALIDATE_RETURN(current != nullptr, EINVAL, nullptr);
if ( _ismbblead(*(current++)))
{
/* don't move forward two if we get leadbyte, EOS
also don't assert here as we are too low level
*/
if(*current!='\0')
{
current++;
}
}
return (unsigned char *)current;
}