c->mlget_task.mlget_num= 0;
c->mlget_task.value_index= -1; /* default invalid value */
- if (ms_setting.binary_prot)
+ if (ms_setting.binary_prot_)
{
c->protocol= binary_prot;
}
*/
limit_to_mtu= c->udp;
+#ifdef IOV_MAX
/* We may need to start a new msghdr if this one is full. */
if ((m->msg_iovlen == IOV_MAX)
|| (limit_to_mtu && (c->msgbytes >= UDP_MAX_SEND_PAYLOAD_SIZE)))
ms_add_msghdr(c);
m= &c->msglist[c->msgused - 1];
}
+#endif
if (ms_ensure_iov_space(c) != 0)
return -1;
{
gettimeofday(&curr_time, NULL);
time_diff= ms_time_diff(&ms_thread->startup_time, &curr_time);
- tps=
- (int64_t)((task->get_opt
- + task->set_opt) / ((uint64_t)time_diff / 1000000));
+ tps= (int64_t)(((task->get_opt + task->set_opt) / (uint64_t)time_diff) * 1000000);
/* current throughput is greater than expected throughput */
if (tps > ms_thread->thread_ctx->tps_perconn)
header->request.extlen= (uint8_t)hdr_len;
header->request.datatype= (uint8_t)PROTOCOL_BINARY_RAW_BYTES;
- header->request.reserved= 0;
+ header->request.vbucket= 0;
header->request.bodylen= htonl(body_len);
header->request.opaque= 0;