Skip to content

Commit

Permalink
Issue connamara#80 - Sequence reset on logon
Browse files Browse the repository at this point in the history
See the bug connamara#80.
  • Loading branch information
TomasVetrovsky committed Mar 12, 2013
1 parent 55cdb0c commit 0344291
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions QuickFIXn/Session.cs
Original file line number Diff line number Diff line change
Expand Up @@ -636,6 +636,13 @@ protected void NextLogon(Message logon)
logon.GetField(resetSeqNumFlag);
state_.ReceivedReset = resetSeqNumFlag.Obj;

if (state_.ReceivedReset)
{
this.Log.OnEvent("Logon contains ResetSeqNumFlag=Y, reseting sequence numbers to 1");
if (!state_.SentReset)
state_.Reset("Reseting because reset was requested by counterparty.");
}

if (!state_.IsInitiator && this.ResetOnLogon)
state_.Reset("ResetOnLogon");

Expand Down

0 comments on commit 0344291

Please sign in to comment.