Skip to content
Permalink
Browse files

Very little optimisation

Change a percentage from uint64_t to uint8_t (this percentage never raise up 100%).
  • Loading branch information...
Jorropo committed Mar 20, 2019
1 parent f2f725d commit 28bd0e9722377b70c142bcc6fde68c1b0ffa8e7c
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/cryptonote_protocol/cryptonote_protocol_handler.inl
@@ -1327,7 +1327,7 @@ namespace cryptonote
std::string progress_message = "";
if (current_blockchain_height < target_blockchain_height)
{
uint64_t completion_percent = (current_blockchain_height * 100 / target_blockchain_height);
uint8_t completion_percent = (current_blockchain_height * 100 / target_blockchain_height);
if (completion_percent == 100) // never show 100% if not actually up to date
completion_percent = 99;
progress_message = " (" + std::to_string(completion_percent) + "%, "

0 comments on commit 28bd0e9

Please sign in to comment.
You can’t perform that action at this time.