| 6146 | #define RDB_EOF_MARK_SIZE 40 |
| 6147 | |
| 6148 | void sendReplconf(const char* arg1, const char* arg2) { |
| 6149 | fprintf(stderr, "sending REPLCONF %s %s\n", arg1, arg2); |
| 6150 | redisReply *reply = redisCommand(context, "REPLCONF %s %s", arg1, arg2); |
| 6151 | |
| 6152 | /* Handle any error conditions */ |
| 6153 | if(reply == NULL) { |
| 6154 | fprintf(stderr, "\nI/O error\n"); |
| 6155 | exit(1); |
| 6156 | } else if(reply->type == REDIS_REPLY_ERROR) { |
| 6157 | fprintf(stderr, "REPLCONF %s error: %s\n", arg1, reply->str); |
| 6158 | /* non fatal, old versions may not support it */ |
| 6159 | } |
| 6160 | freeReplyObject(reply); |
| 6161 | } |
| 6162 | |
| 6163 | void sendCapa() { |
| 6164 | sendReplconf("capa", "eof"); |
no test coverage detected