summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--clients/ms_conn.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/clients/ms_conn.c b/clients/ms_conn.c
index 2afc9fa1..0c2cf090 100644
--- a/clients/ms_conn.c
+++ b/clients/ms_conn.c
@@ -2473,7 +2473,7 @@ static bool ms_need_yield(ms_conn_t *c)
{
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= (uint64_t)(task->get_opt + task->set_opt) * 1000000 / (uint64_t)time_diff;
/* current throughput is greater than expected throughput */
if (tps > ms_thread->thread_ctx->tps_perconn)