Commit 698fd166 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

version up : groonga 4.0.6.

also add a temporary patch to respect more tokens in natural language mode.
parent d99e2549
...@@ -11,9 +11,13 @@ extends = ...@@ -11,9 +11,13 @@ extends =
[groonga] [groonga]
recipe = slapos.recipe.cmmi recipe = slapos.recipe.cmmi
version = 4.0.5 version = 4.0.6
url = http://packages.groonga.org/source/groonga/groonga-${:version}.tar.gz url = http://packages.groonga.org/source/groonga/groonga-${:version}.tar.gz
md5sum = a30fd8674c3a1cf4a6589acfb54f83ed md5sum = d7eb0296b0b759d1856c31b6288670fa
# temporary patch to respect more tokens in natural language mode.
patches =
${:_profile_base_location_}/groonga.patch#9ed02fbe8400402d3eab47eee149978b
patch-options = -p1
configure-options = configure-options =
--disable-static --disable-static
--disable-glibtest --disable-glibtest
......
diff --git a/lib/ii.c b/lib/ii.c
index d10b84d..e20bdce 100644
--- a/lib/ii.c
+++ b/lib/ii.c
@@ -5695,7 +5695,9 @@ grn_ii_similar_search(grn_ctx *ctx, grn_ii *ii,
? (optarg->similarity_threshold > GRN_HASH_SIZE(h)
? GRN_HASH_SIZE(h)
: optarg->similarity_threshold)
- : (GRN_HASH_SIZE(h) >> 3) + 1;
+ : (GRN_HASH_SIZE(h) < 8
+ ? GRN_HASH_SIZE(h)
+ : ((GRN_HASH_SIZE(h) - 8) >> 3) + 8);
if (GRN_HASH_SIZE(h)) {
grn_id j, id;
int w2, rep;
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment