diff options
author | Oran Agra <oran@redislabs.com> | 2019-07-14 17:34:13 +0300 |
---|---|---|
committer | Oran Agra <oran@redislabs.com> | 2019-07-21 18:19:32 +0300 |
commit | d7d028a7a72388cf3908a5f40c8188e68a447dee (patch) | |
tree | 0afc2a8b800ff7fd0731a3c431ec06da436796a6 /src/server.h | |
parent | 3f1c84751a7e665c8831475cd23be1e93285d032 (diff) | |
download | redis-d7d028a7a72388cf3908a5f40c8188e68a447dee.tar.gz |
Allow modules to handle RDB loading errors.
This is especially needed in diskless loading, were a short read could have
caused redis to exit. now the module can handle the error and return to the
caller gracefully.
this fixes #5326
Diffstat (limited to 'src/server.h')
-rw-r--r-- | src/server.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/server.h b/src/server.h index f81b1010e..9957c3b5c 100644 --- a/src/server.h +++ b/src/server.h @@ -599,6 +599,7 @@ typedef struct RedisModuleIO { * 2 (current version with opcodes annotation). */ struct RedisModuleCtx *ctx; /* Optional context, see RM_GetContextFromIO()*/ struct redisObject *key; /* Optional name of key processed */ + int flags; /* flags declaring capabilities or behavior */ } RedisModuleIO; /* Macro to initialize an IO context. Note that the 'ver' field is populated @@ -611,6 +612,7 @@ typedef struct RedisModuleIO { iovar.ver = 0; \ iovar.key = keyptr; \ iovar.ctx = NULL; \ + iovar.flags = 0; \ } while(0); /* This is a structure used to export DEBUG DIGEST capabilities to Redis |