Skip to content

Commit 9711782

Browse files
committed
Fix incorrect length of lexemes in silly_cmp_tsvector()
1 parent cda6d0a commit 9711782

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

contrib/tsearch2/tsvector.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -979,7 +979,7 @@ silly_cmp_tsvector(const tsvector * a, const tsvector * b)
979979
return ( aptr->pos > bptr->pos ) ? -1 : 1;
980980
} else if ( aptr->len != bptr->len ) {
981981
return ( aptr->len > bptr->len ) ? -1 : 1;
982-
} else if ( (res=strncmp(STRPTR(a) + aptr->pos, STRPTR(b) + bptr->pos, b->len))!= 0 ) {
982+
} else if ( (res=strncmp(STRPTR(a) + aptr->pos, STRPTR(b) + bptr->pos, bptr->len))!= 0 ) {
983983
return res;
984984
} else if ( aptr->haspos ) {
985985
WordEntryPos *ap = POSDATAPTR(a, aptr);

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy