Creates a string from a stream ID. The returned string must be released with * RedisModule_FreeString(), unless automatic memory is enabled. * * The passed context `ctx` may be NULL if necessary. See the * RedisModule_CreateString() documentation for more info. */
| 1216 | * The passed context `ctx` may be NULL if necessary. See the |
| 1217 | * RedisModule_CreateString() documentation for more info. */ |
| 1218 | RedisModuleString *RM_CreateStringFromStreamID(RedisModuleCtx *ctx, const RedisModuleStreamID *id) { |
| 1219 | streamID streamid = {id->ms, id->seq}; |
| 1220 | RedisModuleString *o = createObjectFromStreamID(&streamid); |
| 1221 | if (ctx != NULL) autoMemoryAdd(ctx, REDISMODULE_AM_STRING, o); |
| 1222 | return o; |
| 1223 | } |
| 1224 | |
| 1225 | /* Free a module string object obtained with one of the Redis modules API calls |
| 1226 | * that return new string objects. |
nothing calls this directly
no test coverage detected