Commit c07ad274 authored by Bradley C. Kuszmaul's avatar Bradley C. Kuszmaul Committed by Yoni Fogel

Get rid of more cil warnings. Addresses #1185.

git-svn-id: file:///svn/tokudb.1131b+1080a+1185@6459 c7de825b-a66e-492c-adef-691d508d4ae1
parent 2c0a2148
......@@ -190,3 +190,4 @@ testdump: brtdump
TAGS: ../*/*.c ../*/*.h
etags ../*/*.c ../*/*.h
ofiles: $(OFILES)
......@@ -313,9 +313,9 @@ int toku_cachefile_close (CACHEFILE *cfp, TOKULOGGER logger) {
assert(r == 0);
cf->fd = -1;
if (logger) {
assert(cf->fname);
BYTESTRING bs = {.len=strlen(cf->fname), .data=cf->fname};
r = toku_log_cfclose(logger, 0, 0, bs, cf->filenum);
//assert(cf->fname);
//BYTESTRING bs = {.len=strlen(cf->fname), .data=cf->fname};
//r = toku_log_cfclose(logger, 0, 0, bs, cf->filenum);
}
if (cf->fname)
toku_free(cf->fname);
......
......@@ -8,6 +8,7 @@
#include <arpa/inet.h>
#include <ctype.h>
#include <dirent.h>
#include <errno.h>
#include <inttypes.h>
#include <malloc.h>
......
/* -*- mode: C; c-basic-offset: 4 -*- */
#ident "Copyright (c) 2007, 2008 Tokutek Inc. All rights reserved."
#include <arpa/inet.h>
#include <ctype.h>
#include <dirent.h>
#include <errno.h>
#include <fcntl.h>
#include <inttypes.h>
#include <limits.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/stat.h>
#include <sys/types.h>
#include <sys/uio.h>
#include <unistd.h>
#include "brt-internal.h"
#include "log-internal.h"
#include "wbuf.h"
#include "memory.h"
#include "log_header.h"
#include "includes.h"
static char dev_null[] = "/dev/null";
......@@ -624,7 +605,9 @@ int toku_fread_DISKOFF (FILE *f, DISKOFF *diskoff, struct x1764 *checksum, u_int
return r;
}
int toku_fread_BLOCKNUM (FILE *f, BLOCKNUM *blocknum, struct x1764 *checksum, u_int32_t *len) {
int r = toku_fread_u_int64_t (f, (u_int64_t*)&blocknum->b, checksum, len); // sign conversion will be OK.
u_int64_t b;
int r = toku_fread_u_int64_t (f, &b, checksum, len); // sign conversion will be OK.
blocknum->b=b;
return r;
}
int toku_fread_TXNID (FILE *f, TXNID *txnid, struct x1764 *checksum, u_int32_t *len) {
......
......@@ -7,17 +7,7 @@
// cd ../src/tests/tmpdir
// ../../../newbrt/recover ../dir.test_log2.c.tdb
#include "cachetable.h"
#include "key.h"
#include "log-internal.h"
#include "log_header.h"
#include "toku_assert.h"
#include <fcntl.h>
#include <stdlib.h>
#include <sys/file.h>
#include <sys/stat.h>
#include <unistd.h>
#include "includes.h"
int main (int argc, char *argv[]) {
assert(argc==2);
......
......@@ -131,8 +131,6 @@ ifeq ($(CIL),1)
endif
build: $(BINS)
foo:
echo $(BINS)
check: $(patsubst %,check_%,$(CHECKS))
check_fail:
......@@ -199,3 +197,5 @@ test-inc-split test-del-inorder: ../brt-test-helpers.o
clean:
rm -rf $(BINS) *.o *.bb *.bbg *.da *.gcov *.gcno *.gcda
rm -rf test_oexcl.c.tmp *.brt *.dir *.tdb *.dat *.out
foo: ../cachetable.o ../fifo.o ../fingerprint.o ../key.o ../memory.o ../memarena.o ../mempool.o ../omt.o ../toku_assert.o ../ybt.o ../x1764.o ../trace_mem.o ../threadpool.o
......@@ -49,7 +49,7 @@ test_simple_enq_deq (int n) {
assert(!writequeue_empty(wq));
}
for (i=0; i<n; i++) {
PAIR p;
PAIR p = 0;
r = writequeue_deq(wq, &mutex, &p);
assert(r == 0 && p == pairs[i]);
destroy_pair(p);
......
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