Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitdfc0e45

Browse files
committed
Fixed bug in copyAffixNode (ommited the 'val' field, so the FindAffixes failed).
1 parent72fb026 commitdfc0e45

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

‎src/shared_ispell.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -544,8 +544,9 @@ AFFIX * copyAffix(AFFIX * affix) {
544544

545545
if (copy->isregis) {
546546
copy->reg.regis.node=copyRegisNode(copy->reg.regis.node);
547-
}else {
547+
}elseif (!copy->issimple){
548548
// FIXME handle the regex_t properly (copy the strings etc)
549+
elog(WARNING,"skipping regex_t");
549550
}
550551

551552
returncopy;
@@ -563,14 +564,13 @@ AffixNode * copyAffixNode(AffixNode * node) {
563564
}
564565

565566
copy= (AffixNode*)shalloc(offsetof(AffixNode,data)+sizeof(AffixNodeData)*node->length);
566-
copy->isvoid=node->isvoid;
567-
copy->length=node->length;
568567
memcpy(copy,node, offsetof(SPNode,data)+sizeof(SPNodeData)*node->length);
569568

570569
for (i=0;i<node->length;i++) {
571570

572571
copy->data[i].node=copyAffixNode(node->data[i].node);
573572

573+
copy->data[i].val=node->data[i].val;
574574
copy->data[i].naff=node->data[i].naff;
575575
copy->data[i].aff= (AFFIX**)shalloc(sizeof(AFFIX*)*node->data[i].naff);
576576
memset(copy->data[i].aff,0,sizeof(AFFIX*)*node->data[i].naff);

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp