comparison in hiredis

10 views
Skip to first unread message

Peng Wang

unread,
Aug 29, 2021, 10:26:54 AM8/29/21
to redi...@googlegroups.com
Hi, how to compare a redisreply object to a string?

A multi bulk reply. The number of elements in the multi bulk reply is stored in
reply->elements. Every element in the multi bulk reply is a redisReply object as well
and can be accessed via reply->element[..index..].
Redis may reply with nested arrays but this is fully supported.
I want to compare the reply->element[..index..] to a string. Let's say: reply->element[i]->str != "(null)" But this is not working now.

How to do this?
Thank you
Reply all
Reply to author
Forward
0 new messages