Skip to content

Commit 0ed8c46

Browse files
author
Jayant Krishnamurthy
committed
fix build
1 parent fa56b71 commit 0ed8c46

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

pc/user.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,14 @@ void user::user_http::parse_content( const char *txt, size_t len )
2929
user::user()
3030
: rptr_( nullptr ),
3131
sptr_( nullptr ),
32-
psub_( this ),
33-
last_update_ts_(0)
32+
psub_( this )
3433
{
3534
// setup the plumbing
3635
hsvr_.ptr_ = this;
3736
hsvr_.set_net_connect( this );
3837
hsvr_.set_ws_parser( this );
3938
set_net_parser( &hsvr_ );
39+
last_upd_ts_ = get_now();
4040
}
4141

4242
void user::set_rpc_client( rpc_client *rptr )
@@ -337,7 +337,7 @@ void user::send_pending_upds()
337337
{
338338
uint32_t n_sent = 0;
339339
int64_t curr_ts = get_now();
340-
if (curr_ts_ - price_upd_ts_ > PC_FLUSH_INTERVAL) {
340+
if (curr_ts - last_upd_ts_ > PC_FLUSH_INTERVAL) {
341341
n_sent = pending_vec_.size();
342342
} else if (pending_vec_.size() > max_batch_size_) {
343343
n_sent = max_batch_size_;
@@ -352,7 +352,7 @@ void user::send_pending_upds()
352352
}
353353

354354
pending_vec_.erase(pending_vec_.begin(), pending_vec_.begin() + n_sent);
355-
price_upd_ts_ = curr_ts_;
355+
last_upd_ts_ = curr_ts;
356356
}
357357

358358
void user::parse_get_all_products( uint32_t itok )

0 commit comments

Comments
 (0)