ArjunVachhani / order-matcher

simple, fast and feature rich order matching engine supports limit, market, stop-loss, iceberg, IOC, FOK, GTD orders
MIT License
137 stars 70 forks source link

fixed bug for invalid quantity calculation for market buy order with amount #31

Closed ArjunVachhani closed 2 years ago

ArjunVachhani commented 2 years ago

Market buy order quantity was calculated incorrectly. Happens only for market buy with OrderAmount orders only. in result market order is filled more than requested.