Commit 57d8fd13 authored by Yoni Fogel's avatar Yoni Fogel

Addresses #993

Bugfix in comparison in heaviside funcs

git-svn-id: file:///svn/mysql/tokudb-engine/src@5154 c7de825b-a66e-492c-adef-691d508d4ae1
parent 20112213
......@@ -2618,7 +2618,7 @@ typedef struct heavi_info {
//
static int after_key_heavi(const DBT *key, const DBT *value, void *extra_h) {
HEAVI_INFO info = (HEAVI_INFO)extra_h;
int cmp = tokudb_prefix_cmp_packed_key(info->db, info->key, key);
int cmp = tokudb_prefix_cmp_packed_key(info->db, key, info->key);
return cmp>0 ? 1 : -1;
}
......@@ -2648,7 +2648,7 @@ static int after_key_heavi(const DBT *key, const DBT *value, void *extra_h) {
//
static int prefix_last_or_prev_heavi(const DBT *key, const DBT *value, void *extra_h) {
HEAVI_INFO info = (HEAVI_INFO)extra_h;
int cmp = tokudb_prefix_cmp_packed_key(info->db, info->key, key);
int cmp = tokudb_prefix_cmp_packed_key(info->db, key, info->key);
return cmp;
}
......@@ -2677,7 +2677,7 @@ static int prefix_last_or_prev_heavi(const DBT *key, const DBT *value, void *ext
//
static int before_key_heavi(const DBT *key, const DBT *value, void *extra_h) {
HEAVI_INFO info = (HEAVI_INFO)extra_h;
int cmp = tokudb_prefix_cmp_packed_key(info->db, info->key, key);
int cmp = tokudb_prefix_cmp_packed_key(info->db, key, info->key);
return (cmp<0) ? -1 : 1;
}
......
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