MCPcopy Create free account
hub / github.com/F-Stack/f-stack / moduleUnsubscribeNotifications

Function moduleUnsubscribeNotifications

app/redis-6.2.6/src/module.c:5969–5980  ·  view source on GitHub ↗

Unsubscribe any notification subscribers this module has upon unloading */

Source from the content-addressed store, hash-verified

5967
5968/* Unsubscribe any notification subscribers this module has upon unloading */
5969void moduleUnsubscribeNotifications(RedisModule *module) {
5970 listIter li;
5971 listNode *ln;
5972 listRewind(moduleKeyspaceSubscribers,&li);
5973 while((ln = listNext(&li))) {
5974 RedisModuleKeyspaceSubscriber *sub = ln->value;
5975 if (sub->module == module) {
5976 listDelNode(moduleKeyspaceSubscribers, ln);
5977 zfree(sub);
5978 }
5979 }
5980}
5981
5982/* --------------------------------------------------------------------------
5983 * ## Modules Cluster API

Callers 1

moduleUnloadFunction · 0.85

Calls 4

listRewindFunction · 0.85
listNextFunction · 0.85
listDelNodeFunction · 0.85
zfreeFunction · 0.70

Tested by

no test coverage detected