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 ...@@ -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); else toku_free(t->temp_descriptor.dbt.data);
t->temp_descriptor.dbt.data = NULL; 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 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) { ...@@ -3117,7 +3117,7 @@ int toku_brt_get_fd(BRT brt, int *fdp) {
} }
int toku_brt_set_flags(BRT brt, unsigned int flags) { int toku_brt_set_flags(BRT brt, unsigned int flags) {
brt->did_set_flags = 1; brt->did_set_flags = TRUE;
brt->flags = flags; brt->flags = flags;
return 0; return 0;
} }
...@@ -3406,7 +3406,7 @@ toku_brt_set_descriptor (BRT t, u_int32_t version, const DBT* descriptor, toku_d ...@@ -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); toku_fill_dbt(&t->temp_descriptor.dbt, copy, descriptor->size);
assert(!t->dbt_userformat_upgrade); assert(!t->dbt_userformat_upgrade);
t->dbt_userformat_upgrade = dbt_userformat_upgrade; t->dbt_userformat_upgrade = dbt_userformat_upgrade;
t->did_set_descriptor = 1; t->did_set_descriptor = TRUE;
r = 0; r = 0;
} }
} }
......
...@@ -282,7 +282,7 @@ static inline BOOL toku__ltm_lock_test_incr(toku_ltm* tree_mgr, ...@@ -282,7 +282,7 @@ static inline BOOL toku__ltm_lock_test_incr(toku_ltm* tree_mgr,
u_int32_t replace_locks) { u_int32_t replace_locks) {
assert(tree_mgr); assert(tree_mgr);
assert(replace_locks <= tree_mgr->curr_locks); 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) { 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, ...@@ -302,8 +302,8 @@ static inline BOOL toku__lt_lock_test_incr_per_db(toku_lock_tree* tree,
u_int32_t replace_locks) { u_int32_t replace_locks) {
assert(tree); assert(tree);
assert(replace_locks <= tree->curr_locks); assert(replace_locks <= tree->curr_locks);
return (BOOL)(tree->curr_locks - replace_locks < tree->max_locks) && return (BOOL)((tree->curr_locks - replace_locks < tree->max_locks) &&
toku__ltm_lock_test_incr(tree->mgr, replace_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) { 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) { ...@@ -357,7 +357,7 @@ static int needs_recovery (DB_ENV *env) {
} else { } else {
logdir = toku_strdup(env->i->dir); 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); toku_free(logdir);
return recovery_needed ? DB_RUNRECOVERY : 0; 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 ...@@ -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; char* full_dir = NULL;
if (env->i->lg_dir) full_dir = construct_full_name(2, env->i->dir, env->i->lg_dir); if (env->i->lg_dir) full_dir = construct_full_name(2, env->i->dir, env->i->lg_dir);
assert(env->i->logger); 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); r = toku_logger_open(full_dir ? full_dir : env->i->dir, env->i->logger);
if (full_dir) toku_free(full_dir); if (full_dir) toku_free(full_dir);
if (r!=0) { 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