Browse Source

Don't use safecmp for blockupdate since a null buf can be passed on

master
Con Kolivas 10 years ago
parent
commit
1e0c1b4e34
  1. 2
      src/stratifier.c

2
src/stratifier.c

@ -1088,7 +1088,7 @@ static void *blockupdate(void *arg)
while (42) { while (42) {
dealloc(buf); dealloc(buf);
buf = send_recv_proc(ckp->generator, request); buf = send_recv_proc(ckp->generator, request);
if (safecmp(buf, hash) && !cmdmatch(buf, "failed")) { if (buf && strcmp(buf, hash) && !cmdmatch(buf, "failed")) {
strcpy(hash, buf); strcpy(hash, buf);
LOGNOTICE("Block hash changed to %s", hash); LOGNOTICE("Block hash changed to %s", hash);
send_proc(ckp->stratifier, "update"); send_proc(ckp->stratifier, "update");

Loading…
Cancel
Save