mirror of
https://github.com/reactos/reactos.git
synced 2025-06-20 07:36:05 +00:00
Create a branch for audio work
svn path=/branches/audio-bringup/; revision=49478
This commit is contained in:
parent
26c20f3857
commit
5eb25b5c24
20759 changed files with 0 additions and 1141005 deletions
|
@ -1,53 +0,0 @@
|
|||
/*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
* FILE: lib/sdk/crt/mbstring/ismblead.c
|
||||
* PURPOSE: Checks for a leading byte
|
||||
* PROGRAMERS:
|
||||
* Copyright 1999 Ariadne, Taiji Yamada
|
||||
* Copyright 1999 Alexandre Julliard
|
||||
* Copyright 2000 Jon Griffths
|
||||
* Copyright 2008 Samuel Serapion adapted from PROJECT C Library
|
||||
*
|
||||
*/
|
||||
|
||||
#include <precomp.h>
|
||||
#include <mbctype.h>
|
||||
|
||||
/*
|
||||
* @implemented
|
||||
*/
|
||||
int _ismbblead(unsigned int c)
|
||||
{
|
||||
return (_mbctype[(c&0xff) + 1] & _M1) != 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* @implemented
|
||||
*/
|
||||
int _ismbslead( const unsigned char *start, const unsigned char *str)
|
||||
{
|
||||
int lead = 0;
|
||||
|
||||
/* Lead bytes can also be trail bytes so we need to analyse the string
|
||||
*/
|
||||
while (start <= str)
|
||||
{
|
||||
if (!*start)
|
||||
return 0;
|
||||
lead = !lead && _ismbblead(*start);
|
||||
start++;
|
||||
}
|
||||
|
||||
return lead ? -1 : 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* @implemented
|
||||
*/
|
||||
unsigned char *__p__mbctype(void)
|
||||
{
|
||||
return _mbctype;
|
||||
}
|
||||
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue