1
0
Fork 0

return the len of the string

This commit is contained in:
ehofman 2009-06-04 11:03:27 +00:00 committed by Tim Moore
parent 5ae40c1c30
commit 373849dab3

View file

@ -619,7 +619,7 @@ xmlNodeCopyString(const void *id, const char *path, char *buffer, size_t buflen)
memcpy(buffer, p, len); memcpy(buffer, p, len);
*(buffer+len) = '\0'; *(buffer+len) = '\0';
} }
ret = 0; ret = len;
} }
else if (slen == 0) else if (slen == 0)
{ {
@ -1345,13 +1345,9 @@ __xmlNodeGetPath(void **nc, const char *start, size_t *len, char **name, size_t
assert(start != 0); assert(start != 0);
assert(len != 0); assert(len != 0);
assert(*len != 0);
assert(name != 0); assert(name != 0);
assert(*name != 0); assert(*name != 0);
assert(nlen != 0); assert(nlen != 0);
assert(*nlen != 0);
if (*nlen > *len) return 0;
path = *name; path = *name;
if (*path == '/') path++; if (*path == '/') path++;