projects
/
yaz-moved-to-github.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Return fixed hit count 24 for anything but RPN
[yaz-moved-to-github.git]
/
ztest
/
ztest.c
diff --git
a/ztest/ztest.c
b/ztest/ztest.c
index
bbbb402
..
6cc2bff
100644
(file)
--- a/
ztest/ztest.c
+++ b/
ztest/ztest.c
@@
-133,12
+133,16
@@
static Odr_int get_term_hit(Z_RPNStructure *s)
*/
static Odr_int get_hit_count(Z_Query *q)
{
*/
static Odr_int get_hit_count(Z_Query *q)
{
- Odr_int h = -1;
if (q->which == Z_Query_type_1 || q->which == Z_Query_type_101)
if (q->which == Z_Query_type_1 || q->which == Z_Query_type_101)
+ {
+ Odr_int h = -1;
h = get_term_hit(q->u.type_1->RPNStructure);
h = get_term_hit(q->u.type_1->RPNStructure);
- if (h == -1)
- h = rand() % 24;
- return h;
+ if (h == -1)
+ h = rand() % 24;
+ return h;
+ }
+ else
+ return 24;
}
/** \brief checks if it's a dummy Slow database
}
/** \brief checks if it's a dummy Slow database