diff options
Diffstat (limited to 'src/core/string.c')
-rw-r--r-- | src/core/string.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/core/string.c b/src/core/string.c index 0c82d4e..258b06e 100644 --- a/src/core/string.c +++ b/src/core/string.c @@ -440,7 +440,7 @@ uint32_t dom_string_index(dom_string *str, uint32_t chr) uint32_t dom_string_rindex(dom_string *str, uint32_t chr) { const uint8_t *s; - size_t clen, slen; + size_t clen = 0, slen; uint32_t c, coff, index; parserutils_error err; @@ -686,7 +686,6 @@ dom_exception dom_string_insert(dom_string *target, /* Calculate the byte index of the insertion point */ if (offset == clen) { /* Optimisation for append */ - offset = 0; ins = tlen; } else { while (offset > 0) { |