Merge pull request #9 from dschatzberg/master

Fix incorrect length calculation
This commit is contained in:
Jacob Leverich 2015-06-04 14:13:01 -07:00
commit d65c6ef7c2

View File

@ -160,7 +160,7 @@ int ProtocolBinary::set_request(const char* key, const char* value, int len) {
bufferevent_write(bev, &h, 32); // With extras bufferevent_write(bev, &h, 32); // With extras
bufferevent_write(bev, key, keylen); bufferevent_write(bev, key, keylen);
bufferevent_write(bev, value, len); bufferevent_write(bev, value, len);
return 24 + h.body_len; return 24 + ntohl(h.body_len);
} }
/** /**