diff --git a/doc/user/content/release_notes/_index.md b/doc/user/content/release_notes/_index.md index 41d6c4811..44d33cfc2 100644 --- a/doc/user/content/release_notes/_index.md +++ b/doc/user/content/release_notes/_index.md @@ -12,7 +12,9 @@ insert_anchor_links = "right" - Added security state information (pre open, halted, normal, closed, etc) ### Internal Changes - Fixed an issue that was stopping us from interpreting SOD times as local rather than GMT - +## 2.9.2 +### Bug Fixes + - Fixed an issue with the exchange simulator that could lead to crossed markets ## 2.9.1 ### Bug Fixes - Fixed an issue with trade sound alerts, where in some cases the use of a "In Between" condition could lead to a UI failure. diff --git a/src/server/sparkd/exchange_sim/book/OrderMatcher.cpp b/src/server/sparkd/exchange_sim/book/OrderMatcher.cpp index 2238e4a30..bfcc1e75d 100644 --- a/src/server/sparkd/exchange_sim/book/OrderMatcher.cpp +++ b/src/server/sparkd/exchange_sim/book/OrderMatcher.cpp @@ -178,7 +178,9 @@ void OrderMatcher::match(std::vector *out) { auto iBid = me->bids.begin(); auto iAsk = me->asks.begin(); - if (iBid->price() >= iAsk->price()) { + if (iBid->price() > iAsk->price() || + price_equals(iBid->price(), iAsk->price())) + { Order bid = *iBid; Order ask = *iAsk;