Skip to content

Commit

Permalink
update API to VM_UpdateRuntimeArgs
Browse files Browse the repository at this point in the history
Signed-off-by: hwware <[email protected]>
  • Loading branch information
hwware committed Nov 1, 2024
1 parent b3a0af2 commit c35a618
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions src/module.c
Original file line number Diff line number Diff line change
Expand Up @@ -3042,7 +3042,7 @@ client *moduleGetReplyClient(ValkeyModuleCtx *ctx) {
}
}

int VM_UpdateRunTimeArgs(ValkeyModuleCtx *ctx, int argc, ValkeyModuleString **argv) {
int VM_UpdateRuntimeArgs(ValkeyModuleCtx *ctx, int argc, ValkeyModuleString **argv) {
client *c = moduleGetReplyClient(ctx);
if (c == NULL) return VALKEYMODULE_OK;
struct moduleLoadQueueEntry *loadmod = ctx->module->loadmod;
Expand Down Expand Up @@ -13577,7 +13577,7 @@ void moduleRegisterCoreAPI(void) {
REGISTER_API(SetModuleAttribs);
REGISTER_API(IsModuleNameBusy);
REGISTER_API(WrongArity);
REGISTER_API(UpdateRunTimeArgs);
REGISTER_API(UpdateRuntimeArgs);
REGISTER_API(ReplyWithLongLong);
REGISTER_API(ReplyWithError);
REGISTER_API(ReplyWithErrorFormat);
Expand Down
2 changes: 1 addition & 1 deletion src/redismodule.h
Original file line number Diff line number Diff line change
Expand Up @@ -357,7 +357,7 @@
#define RedisModule_SetModuleAttribs ValkeyModule_SetModuleAttribs
#define RedisModule_IsModuleNameBusy ValkeyModule_IsModuleNameBusy
#define RedisModule_WrongArity ValkeyModule_WrongArity
#define RedisModule_UpdateRunTimeArgs ValkeyModule_UpdateRunTimeArgs
#define RedisModule_UpdateRuntimeArgs ValkeyModule_UpdateRuntimeArgs
#define RedisModule_ReplyWithLongLong ValkeyModule_ReplyWithLongLong
#define RedisModule_GetSelectedDb ValkeyModule_GetSelectedDb
#define RedisModule_SelectDb ValkeyModule_SelectDb
Expand Down
4 changes: 2 additions & 2 deletions src/valkeymodule.h
Original file line number Diff line number Diff line change
Expand Up @@ -967,7 +967,7 @@ VALKEYMODULE_API void (*ValkeyModule_SetModuleAttribs)(ValkeyModuleCtx *ctx, con
VALKEYMODULE_ATTR;
VALKEYMODULE_API int (*ValkeyModule_IsModuleNameBusy)(const char *name) VALKEYMODULE_ATTR;
VALKEYMODULE_API int (*ValkeyModule_WrongArity)(ValkeyModuleCtx *ctx) VALKEYMODULE_ATTR;
VALKEYMODULE_API int (*ValkeyModule_UpdateRunTimeArgs)(ValkeyModuleCtx *ctx, int argc, ValkeyModuleString **argv) VALKEYMODULE_ATTR;
VALKEYMODULE_API int (*ValkeyModule_UpdateRuntimeArgs)(ValkeyModuleCtx *ctx, int argc, ValkeyModuleString **argv) VALKEYMODULE_ATTR;
VALKEYMODULE_API int (*ValkeyModule_ReplyWithLongLong)(ValkeyModuleCtx *ctx, long long ll) VALKEYMODULE_ATTR;
VALKEYMODULE_API int (*ValkeyModule_GetSelectedDb)(ValkeyModuleCtx *ctx) VALKEYMODULE_ATTR;
VALKEYMODULE_API int (*ValkeyModule_SelectDb)(ValkeyModuleCtx *ctx, int newid) VALKEYMODULE_ATTR;
Expand Down Expand Up @@ -1674,7 +1674,7 @@ static int ValkeyModule_Init(ValkeyModuleCtx *ctx, const char *name, int ver, in
VALKEYMODULE_GET_API(SetModuleAttribs);
VALKEYMODULE_GET_API(IsModuleNameBusy);
VALKEYMODULE_GET_API(WrongArity);
VALKEYMODULE_GET_API(UpdateRunTimeArgs);
VALKEYMODULE_GET_API(UpdateRuntimeArgs);
VALKEYMODULE_GET_API(ReplyWithLongLong);
VALKEYMODULE_GET_API(ReplyWithError);
VALKEYMODULE_GET_API(ReplyWithErrorFormat);
Expand Down
2 changes: 1 addition & 1 deletion tests/modules/moduleparameter.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#include <string.h>

int GET_HELLO(ValkeyModuleCtx *ctx, ValkeyModuleString **argv, int argc) {
ValkeyModule_UpdateRunTimeArgs(ctx, argc, argv);
ValkeyModule_UpdateRuntimeArgs(ctx, argc, argv);
return ValkeyModule_ReplyWithSimpleString(ctx, "Module runtime args test");
}

Expand Down

0 comments on commit c35a618

Please sign in to comment.