Overabundant balance check for bid_collateral_operation #1692
Labels
2e Ready for Testing
Status indicating the solution is sufficiently developed to begin testing
3d Bug
Classification indicating the existing implementation does not match the intention of the design
6 DEX
Impact flag identifying the Decentralized EXchange, market engine, etc.
6 Protocol
Impact flag identifying the blockchain logic, consensus, validation, etc.
6 UX
Impact flag identifying the User Interface (UX)
hardfork
Milestone
Bug Description
bitshares-core/libraries/chain/market_evaluator.cpp
Lines 394 to 399 in 71641eb
balance + old_bid_collateral >= new_bid_collateral
, because the old bid will be cancelled so collateral will be released then can be used in the new bid. Additionally, balance will be checked when callingadjust_balance()
later, so the check here is not necessary.Fixing this requires a consensus upgrade.
Impacts
Describe which portion(s) of BitShares Core may be impacted by this bug. Please tick at least one box.
Steps To Reproduce
Steps to reproduce the behavior (example outlined below):
test
with 10000 BTS;Expected Behavior
Able to update bid when
balance + old_bid_collateral >= new_bid_collateral
.Screenshots (optional)
If applicable, add screenshots to help explain process flow and behavior.
Host Environment
Please provide details about the host environment. Much of this information can be found running:
witness_node --version
.Additional Context (optional)
Add any other context about the problem here.
CORE TEAM TASK LIST
The text was updated successfully, but these errors were encountered: