| 105 | } |
| 106 | |
| 107 | bool RedisRequest::AddCommandByComponents(const butil::StringPiece* components, |
| 108 | size_t n) { |
| 109 | if (_has_error) { |
| 110 | return false; |
| 111 | } |
| 112 | const butil::Status st = RedisCommandByComponents(&_buf, components, n); |
| 113 | if (st.ok()) { |
| 114 | ++_ncommand; |
| 115 | return true; |
| 116 | } else { |
| 117 | CHECK(st.ok()) << st; |
| 118 | _has_error = true; |
| 119 | return false; |
| 120 | } |
| 121 | } |
| 122 | |
| 123 | bool RedisRequest::AddCommandWithArgs(const char* fmt, ...) { |
| 124 | if (_has_error) { |