projects
/
yaz-moved-to-github.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f77061f
)
CCL: use strxcat rather than strlen+memcpy
author
Adam Dickmeiss
<adam@indexdata.dk>
Tue, 20 Sep 2011 10:23:24 +0000
(12:23 +0200)
committer
Adam Dickmeiss
<adam@indexdata.dk>
Tue, 20 Sep 2011 10:23:24 +0000
(12:23 +0200)
src/cclfind.c
patch
|
blob
|
history
diff --git
a/src/cclfind.c
b/src/cclfind.c
index
7932ecb
..
a80f154
100644
(file)
--- 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.term, cclp->look_token->ws_prefix_buf,
+ cclp->look_token->ws_prefix_len);
}
for (j = 0; j < src_len; j++)
{