Some valgrind fixes
Former-commit-id: ba974c9810dc30b6b5bd21c4bcc6cc5b219f7ea4
This commit is contained in:
parent
f252cc9e41
commit
ad4d76422c
@ -408,7 +408,7 @@ noopt:
|
|||||||
$(MAKE) OPTIMIZATION="-O0"
|
$(MAKE) OPTIMIZATION="-O0"
|
||||||
|
|
||||||
valgrind:
|
valgrind:
|
||||||
$(MAKE) OPTIMIZATION="-O0" MALLOC="libc" CFLAGS="-DSANITIZE" CXXFLAGS="-DSANITIZE"
|
$(MAKE) OPTIMIZATION="-O0" USEASM="false" MALLOC="libc" CFLAGS="-DSANITIZE" CXXFLAGS="-DSANITIZE"
|
||||||
|
|
||||||
helgrind:
|
helgrind:
|
||||||
$(MAKE) OPTIMIZATION="-O0" MALLOC="libc" CFLAGS="-D__ATOMIC_VAR_FORCE_SYNC_MACROS"
|
$(MAKE) OPTIMIZATION="-O0" MALLOC="libc" CFLAGS="-D__ATOMIC_VAR_FORCE_SYNC_MACROS"
|
||||||
|
@ -294,6 +294,7 @@ int aePostFunction(aeEventLoop *eventLoop, std::function<void()> fn, bool fSynch
|
|||||||
}
|
}
|
||||||
|
|
||||||
aeCommand cmd = {};
|
aeCommand cmd = {};
|
||||||
|
memset(&cmd, 0, sizeof(aeCommand));
|
||||||
cmd.op = AE_ASYNC_OP::PostCppFunction;
|
cmd.op = AE_ASYNC_OP::PostCppFunction;
|
||||||
cmd.pfn = new (MALLOC_LOCAL) std::function<void()>(fn);
|
cmd.pfn = new (MALLOC_LOCAL) std::function<void()>(fn);
|
||||||
cmd.pctl = nullptr;
|
cmd.pctl = nullptr;
|
||||||
|
@ -1173,6 +1173,7 @@ void moveCommand(client *c) {
|
|||||||
/* Return zero if the key already exists in the target DB */
|
/* Return zero if the key already exists in the target DB */
|
||||||
if (lookupKeyWrite(dst,c->argv[1]) != NULL) {
|
if (lookupKeyWrite(dst,c->argv[1]) != NULL) {
|
||||||
addReply(c,shared.czero);
|
addReply(c,shared.czero);
|
||||||
|
decrRefCount(o);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
dbAdd(dst,c->argv[1],o);
|
dbAdd(dst,c->argv[1],o);
|
||||||
|
@ -2561,7 +2561,7 @@ int slaveTryPartialResynchronization(redisMaster *mi, connection *conn, int read
|
|||||||
* establish a connection with the master. */
|
* establish a connection with the master. */
|
||||||
void syncWithMaster(connection *conn) {
|
void syncWithMaster(connection *conn) {
|
||||||
serverAssert(GlobalLocksAcquired());
|
serverAssert(GlobalLocksAcquired());
|
||||||
char tmpfile[256], *err = NULL;
|
char tmpfile[256] = {0}, *err = NULL;
|
||||||
int dfd = -1, maxtries = 5;
|
int dfd = -1, maxtries = 5;
|
||||||
int psync_result;
|
int psync_result;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user