Permalink
Browse files

Fix for DEBUG DIGEST, key may expire on lookup

  • Loading branch information...
1 parent cd128d2 commit cc8a0f898b0aa881064da23dba23f183b13e3195 antirez committed May 13, 2011
Showing with 5 additions and 0 deletions.
  1. +5 −0 src/debug.c
View
@@ -101,6 +101,11 @@ void computeDatasetDigest(unsigned char *final) {
/* Make sure the key is loaded if VM is active */
o = lookupKeyRead(db,keyobj);
+ if (o == NULL) {
+ /* Key expired on lookup? Try the next one. */
+ decrRefCount(keyobj);
+ continue;
+ }
aux = htonl(o->type);
mixDigest(digest,&aux,sizeof(aux));

0 comments on commit cc8a0f8

Please sign in to comment.