mirror of
https://github.com/isar/libmdbx.git
synced 2025-01-30 22:47:16 +08:00
liblmdb: fix warnings in lmdb-tools.
Change-Id: I1a1de4bcb9ce9b27f9278f74535e6e83de25bad0
This commit is contained in:
parent
88b465a6ed
commit
9a76b0a008
2
Makefile
2
Makefile
@ -18,7 +18,7 @@
|
|||||||
# read mdb.c before changing any of them.
|
# read mdb.c before changing any of them.
|
||||||
#
|
#
|
||||||
CC = gcc
|
CC = gcc
|
||||||
W = -W -Wall -Wno-unused-parameter -Wbad-function-cast -Wuninitialized
|
W = -Wall -Werror -Wno-unused-parameter
|
||||||
THREADS = -pthread
|
THREADS = -pthread
|
||||||
XCFLAGS ?= $(CFLAGS)
|
XCFLAGS ?= $(CFLAGS)
|
||||||
OPT = -O2 -g
|
OPT = -O2 -g
|
||||||
|
@ -30,7 +30,7 @@ sighandle(int sig)
|
|||||||
int main(int argc,char * argv[])
|
int main(int argc,char * argv[])
|
||||||
{
|
{
|
||||||
int rc;
|
int rc;
|
||||||
MDB_env *env;
|
MDB_env *env = NULL;
|
||||||
const char *progname = argv[0], *act;
|
const char *progname = argv[0], *act;
|
||||||
unsigned flags = MDB_RDONLY;
|
unsigned flags = MDB_RDONLY;
|
||||||
unsigned cpflags = 0;
|
unsigned cpflags = 0;
|
||||||
|
@ -134,6 +134,10 @@ int main(int argc, char *argv[])
|
|||||||
mei.me_tail_txnid, mei.me_tail_txnid - mei.me_last_txnid);
|
mei.me_tail_txnid, mei.me_tail_txnid - mei.me_last_txnid);
|
||||||
printf(" Max readers: %u\n", mei.me_maxreaders);
|
printf(" Max readers: %u\n", mei.me_maxreaders);
|
||||||
printf(" Number of readers used: %u\n", mei.me_numreaders);
|
printf(" Number of readers used: %u\n", mei.me_numreaders);
|
||||||
|
} else {
|
||||||
|
/* LY: zap warnings from gcc */
|
||||||
|
memset(&mst, 0, sizeof(mst));
|
||||||
|
memset(&mei, 0, sizeof(mei));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (rdrinfo) {
|
if (rdrinfo) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user