Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/rdb.h
Original file line number Diff line number Diff line change
Expand Up @@ -80,12 +80,12 @@
#define RDB_TYPE_HASH_LISTPACK_EX 25 /* Hash LP with HFEs. Attach min TTL at start */
/* NOTE: WHEN ADDING NEW RDB TYPE, UPDATE rdbIsObjectType(), and rdb_type_string[] */
#ifdef ENABLE_SWAP
#define RDB_TYPE_BITMAP 26
#define RDB_TYPE_BITMAP 192
#endif

/* Test if a type is an object type. */
#ifdef ENABLE_SWAP
#define rdbIsObjectType(t) (((t) >= 0 && (t) <= 7) || ((t) >= 9 && (t) <= 26))
#define rdbIsObjectType(t) (((t) >= 0 && (t) <= 7) || ((t) >= 9 && (t) <= 25) || (t) == RDB_TYPE_BITMAP)
#else
#define rdbIsObjectType(t) (((t) >= 0 && (t) <= 7) || ((t) >= 9 && (t) <= 25))
#endif
Expand Down
3 changes: 3 additions & 0 deletions src/redis-check-rdb.c
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,9 @@ void rdbCheckError(const char *fmt, ...) {
if (rdbstate.key_type != -1)
printf("[additional info] Reading type %d (%s)\n",
rdbstate.key_type,
#ifdef ENABLE_SWAP
(rdbstate.key_type == RDB_TYPE_BITMAP) ? "bitmap" :
#endif
((unsigned)rdbstate.key_type <
sizeof(rdb_type_string)/sizeof(char*)) ?
rdb_type_string[rdbstate.key_type] : "unknown");
Expand Down
Loading