Commit 68220312 authored by Rich Prohaska's avatar Rich Prohaska Committed by Yoni Fogel

fix some linux build problems with icc 11 close[t:2088]

git-svn-id: file:///svn/toku/tokudb@15149 c7de825b-a66e-492c-adef-691d508d4ae1
parent 6e3ddb3d
......@@ -3087,7 +3087,7 @@ int toku_brt_open(BRT t, const char *fname, const char *fname_in_env, int is_cre
}
else toku_free(t->temp_descriptor.dbt.data);
t->temp_descriptor.dbt.data = NULL;
t->did_set_descriptor = 0;
t->did_set_descriptor = FALSE;
}
r = toku_maybe_upgrade_brt(t); // possibly do some work to complete the version upgrade of brt
......@@ -3117,7 +3117,7 @@ int toku_brt_get_fd(BRT brt, int *fdp) {
}
int toku_brt_set_flags(BRT brt, unsigned int flags) {
brt->did_set_flags = 1;
brt->did_set_flags = TRUE;
brt->flags = flags;
return 0;
}
......@@ -3406,7 +3406,7 @@ toku_brt_set_descriptor (BRT t, u_int32_t version, const DBT* descriptor, toku_d
toku_fill_dbt(&t->temp_descriptor.dbt, copy, descriptor->size);
assert(!t->dbt_userformat_upgrade);
t->dbt_userformat_upgrade = dbt_userformat_upgrade;
t->did_set_descriptor = 1;
t->did_set_descriptor = TRUE;
r = 0;
}
}
......
......@@ -282,7 +282,7 @@ static inline BOOL toku__ltm_lock_test_incr(toku_ltm* tree_mgr,
u_int32_t replace_locks) {
assert(tree_mgr);
assert(replace_locks <= tree_mgr->curr_locks);
return tree_mgr->curr_locks - replace_locks < tree_mgr->max_locks;
return (BOOL)(tree_mgr->curr_locks - replace_locks < tree_mgr->max_locks);
}
static inline void toku__ltm_lock_incr(toku_ltm* tree_mgr, u_int32_t replace_locks) {
......@@ -302,8 +302,8 @@ static inline BOOL toku__lt_lock_test_incr_per_db(toku_lock_tree* tree,
u_int32_t replace_locks) {
assert(tree);
assert(replace_locks <= tree->curr_locks);
return (BOOL)(tree->curr_locks - replace_locks < tree->max_locks) &&
toku__ltm_lock_test_incr(tree->mgr, replace_locks);
return (BOOL)((tree->curr_locks - replace_locks < tree->max_locks) &&
toku__ltm_lock_test_incr(tree->mgr, replace_locks));
}
static inline void toku__lt_lock_incr_per_db(toku_lock_tree* tree, u_int32_t replace_locks) {
......
......@@ -357,7 +357,7 @@ static int needs_recovery (DB_ENV *env) {
} else {
logdir = toku_strdup(env->i->dir);
}
BOOL recovery_needed = tokudb_needs_recovery(logdir, TRUE);
BOOL recovery_needed = (BOOL) tokudb_needs_recovery(logdir, TRUE);
toku_free(logdir);
return recovery_needed ? DB_RUNRECOVERY : 0;
}
......@@ -449,7 +449,7 @@ static int toku_env_open(DB_ENV * env, const char *home, u_int32_t flags, int mo
char* full_dir = NULL;
if (env->i->lg_dir) full_dir = construct_full_name(2, env->i->dir, env->i->lg_dir);
assert(env->i->logger);
toku_logger_write_log_files(env->i->logger, (flags & DB_INIT_LOG) != 0);
toku_logger_write_log_files(env->i->logger, (BOOL)((flags & DB_INIT_LOG) != 0));
r = toku_logger_open(full_dir ? full_dir : env->i->dir, env->i->logger);
if (full_dir) toku_free(full_dir);
if (r!=0) {
......
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