Commit 10c74e91 authored by Yoni Fogel's avatar Yoni Fogel

[t:2308] Fix db-benchmark tests that used void* arithmetic

git-svn-id: file:///svn/toku/tokudb@17017 c7de825b-a66e-492c-adef-691d508d4ae1
parent 15be993d
...@@ -138,8 +138,8 @@ put_multiple_generate(DBT *row, uint32_t num_dbs_in, DB **dbs_in, DBT *keys, DBT ...@@ -138,8 +138,8 @@ put_multiple_generate(DBT *row, uint32_t num_dbs_in, DB **dbs_in, DBT *keys, DBT
assert((int)row->size >= 4+keysize); assert((int)row->size >= 4+keysize);
int32_t row_valsize = row->size - 4 - keysize; int32_t row_valsize = row->size - 4 - keysize;
assert(row_valsize == valsize); assert(row_valsize == valsize);
void *key = row->data+4; void *key = ((uint8_t*)row->data)+4;
void *val = row->data+4 + keysize; void *val = ((uint8_t*)row->data)+4 + keysize;
for (which = 0; which < num_dbs; which++) { for (which = 0; which < num_dbs; which++) {
assert(dbs_in[which] == dbs[which]); assert(dbs_in[which] == dbs[which]);
keys[which].size = keysize; keys[which].size = keysize;
......
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