Skip to content

Commit

Permalink
CLEANUP : reflected minwoojin review
Browse files Browse the repository at this point in the history
  • Loading branch information
jooho812 committed Sep 15, 2017
1 parent 17aaf07 commit c8e71d8
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
1 change: 0 additions & 1 deletion engines/default/items.c
Original file line number Diff line number Diff line change
Expand Up @@ -4483,7 +4483,6 @@ static ENGINE_ERROR_CODE do_btree_elem_get(struct default_engine *engine, btree_
#endif
uint32_t *access_count, bool *potentialbkeytrim)
{

btree_elem_posi path[BTREE_MAX_DEPTH];
btree_elem_item *elem;
uint32_t tot_found = 0; /* total found count */
Expand Down
3 changes: 2 additions & 1 deletion include/memcached/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -405,8 +405,9 @@ extern "C" {
#define EBLOCK_SCAN_NEXT(s, e) \
do { \
if ((s)->idx < (s)->tot) { \
if (((s)->idx % EITEMS_PER_BLOCK) == 0 && ((s)->idx != 0)) \
if (((s)->idx % EITEMS_PER_BLOCK) == 0 && ((s)->idx != 0)) { \
(s)->blk = ((s)->blk)->next; \
} \
(e) = ((s)->blk)->items[(s)->idx++ % EITEMS_PER_BLOCK]; \
} else { \
(e) = NULL; \
Expand Down
6 changes: 2 additions & 4 deletions memcached.c
Original file line number Diff line number Diff line change
Expand Up @@ -5827,6 +5827,7 @@ static void process_bin_bop_get(conn *c) {
case ENGINE_SUCCESS:
{
protocol_binary_response_bop_get* rsp = (protocol_binary_response_bop_get*)c->wbuf;
eitem_info info[elem_count];
#ifdef USE_EBLOCK_RESULT
eitem *elem;
eblock_scan_t eblk_sc;
Expand All @@ -5846,10 +5847,7 @@ static void process_bin_bop_get(conn *c) {
ret = ENGINE_ENOMEM;
} else {
vlenptr = (uint32_t *)((char*)bkeyptr + (sizeof(uint64_t) * elem_count));
#endif
eitem_info info[elem_count];
#ifdef USE_EBLOCK_RESULT
EBLOCK_SCAN_INIT(&c->eblk_ret, &eblk_sc);
EBLOCK_SCAN_INIT(&c->eblk_ret, &eblk_sc);
#endif
for (i = 0; i < elem_count; i++) {
#ifdef USE_EBLOCK_RESULT
Expand Down

0 comments on commit c8e71d8

Please sign in to comment.