Can we set C int array as a key's value in Redis by hiredis?
问题 given : int x[3] = {11,22,33}; how can save it as a key's value as binary data and get it the hiredis give example to how to set binary safestring /* Set a key using binary safe API */ reply = redisCommand(c,"SET %b %b", "bar", (size_t) 3, "hello", (size_t) 5); printf("SET (binary API): %s\n", reply->str); freeReplyObject(reply); but how about other data and how to get ? 回答1: Storing directly binary data in a remote store without any kind of marshalling is a recipe for disaster. I would not