Return the reply type length, where applicable. */
| 3905 | |
| 3906 | /* Return the reply type length, where applicable. */ |
| 3907 | size_t RM_CallReplyLength(RedisModuleCallReply *reply) { |
| 3908 | moduleParseCallReply(reply); |
| 3909 | switch(reply->type) { |
| 3910 | case REDISMODULE_REPLY_STRING: |
| 3911 | case REDISMODULE_REPLY_ERROR: |
| 3912 | case REDISMODULE_REPLY_ARRAY: |
| 3913 | return reply->len; |
| 3914 | default: |
| 3915 | return 0; |
| 3916 | } |
| 3917 | } |
| 3918 | |
| 3919 | /* Return the 'idx'-th nested call reply element of an array reply, or NULL |
| 3920 | * if the reply type is wrong or the index is out of range. */ |
nothing calls this directly
no test coverage detected