Commit 6551f71f authored by Yoni Fogel's avatar Yoni Fogel

Addresses #1032

Removed over-active warnings, moved struct definition to proper place.

git-svn-id: file:///svn/tokudb@5322 c7de825b-a66e-492c-adef-691d508d4ae1
parent 4cb3a01c
......@@ -20,7 +20,7 @@ cscope.files: $(CSCOPE_DIRS)
@echo "$(CSCOPE_FILES)" | tr " " "\n" > $@ # Very long command line quieted.
cscope.out: cscope.files $(CSCOPE_FILES)
mlcscope -b
$(CSCOPE) -b
src.dir: newbrt.dir
cxx.dir: src.dir
......
......@@ -32,7 +32,7 @@ FPICFLAGS = -fPIC
VGRIND = valgrind --quiet --error-exitcode=1 --leak-check=yes
VISIBILITY=-fvisibility=hidden
SHADOW=-Wshadow
FORMAT=-Wformat=2 -Wmissing-format-attribute
FORMAT=-Wmissing-format-attribute
endif
CFLAGS = -Wall -Wextra -Wcast-align -Wbad-function-cast -Wmissing-noreturn $(FORMAT) $(OPTFLAGS) -g3 -ggdb3 $(GCOV_FLAGS) $(PROF_FLAGS) -Werror $(FPICFLAGS) $(SHADOW) $(VISIBILITY)
......
......@@ -453,6 +453,13 @@ int toku_deserialize_brtnode_from (int fd, DISKOFF off, u_int32_t fullhash, BRTN
return 0;
}
struct sum_info {
unsigned int dsum;
unsigned int msum;
unsigned int count;
u_int32_t fp;
};
int sum_item (OMTVALUE lev, u_int32_t UU(idx), void *vsi) {
LEAFENTRY le=lev;
struct sum_info *si = vsi;
......@@ -467,12 +474,7 @@ void toku_verify_counts (BRTNODE node) {
/*foo*/
if (node->height==0) {
assert(node->u.l.buffer);
struct sum_info {
unsigned int dsum;
unsigned int msum;
unsigned int count;
u_int32_t fp;
} sum_info = {0,0,0,0};
struct sum_info sum_info = {0,0,0,0};
toku_omt_iterate(node->u.l.buffer, sum_item, &sum_info);
assert(sum_info.count==toku_omt_size(node->u.l.buffer));
assert(sum_info.dsum==node->u.l.n_bytes_in_buffer);
......
......@@ -29,7 +29,7 @@ FPICFLAGS = -fPIC
VGRIND = valgrind --quiet --error-exitcode=1 --leak-check=yes
VISIBILITY=-fvisibility=hidden
SHADOW=-Wshadow
FORMAT=-Wformat=2 -Wmissing-format-attribute
FORMAT=-Wmissing-format-attribute
endif
CFLAGS = -Wall -Wextra -Wcast-align -Wbad-function-cast -Wmissing-noreturn $(FORMAT) $(OPTFLAGS) -g3 -ggdb3 $(GCOV_FLAGS) $(PROF_FLAGS) -Werror $(FPICFLAGS) $(SHADOW) $(VISIBILITY)
......
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