added some experimental code for namespace handling

This commit is contained in:
hyunghwan.chung
2015-07-12 17:14:21 +00:00
parent f2ec2d5fd2
commit f97eb3d72b
7 changed files with 117 additions and 40 deletions

View File

@ -217,6 +217,20 @@ void stix_copychars (stix_uch_t* dst, const stix_uch_t* src, stix_size_t len)
for (i = 0; i < len; i++) dst[i] = src[i];
}
stix_uch_t* stix_findchar (const stix_uch_t* ptr, stix_size_t len, stix_uch_t c)
{
const stix_uch_t* end;
end = ptr + len;
while (ptr < end)
{
if (*ptr == c) return (stix_uch_t*)ptr;
ptr++;
}
return STIX_NULL;
}
void* stix_allocmem (stix_t* stix, stix_size_t size)
{
void* ptr;