X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=src%2Fcclfind.c;h=131ec27d33e3af37fd154bcb29c3808d7c237ed5;hb=8f09a31746ca9b1450cce6106b89f9cfbf53e88f;hp=7932ecbd099a257d1c02cd69d9dc9b0f74550b7d;hpb=c508282c3e52e145f998d0bb85c0ea6b36fe956c;p=yaz-moved-to-github.git diff --git a/src/cclfind.c b/src/cclfind.c index 7932ecb..131ec27 100644 --- a/src/cclfind.c +++ b/src/cclfind.c @@ -385,10 +385,8 @@ static struct ccl_rpn_node *search_term_x(CCL_parser cclp, if (p->u.t.term[0] && cclp->look_token->ws_prefix_len) { - size_t len = strlen(p->u.t.term); - memcpy(p->u.t.term + len, cclp->look_token->ws_prefix_buf, - cclp->look_token->ws_prefix_len); - p->u.t.term[len + cclp->look_token->ws_prefix_len] = '\0'; + strxcat(p->u.t.term, cclp->look_token->ws_prefix_buf, + cclp->look_token->ws_prefix_len); } for (j = 0; j < src_len; j++) {