Re: [Quickfix-developers] BUG in Session.cpp. Messages not being resent.
Brought to you by:
orenmnero
From: Oren M. <ore...@ya...> - 2003-06-18 19:20:05
|
What do you think about instead pulling: messageString = message.toString(); up to line 413, and passing the messageString into send on lines 425 and 433. --- Vitor Castro <vc...@hi...> wrote: > Hi Oren, > > I found what I think is a bug introduced during the > last optimization > done on Session.cpp regarding the use of the > toString() methods: > > In Session::sendRaw has the following code: > > 432 if ( isLoggedOn() ) result = > 433 send( message.toString(messageString) ); > > ... > ... > > 441 m_state.set( msgSeqNum, messageString > ); > > In which messageString is being changed by the > toString method as a side > effect. The problem is that it is only changed if > the session is logged > on and is being used in line 441 to store the > message in the > messageStore. > > The effect of this is that if some message is > generated while the other > party is disconnected, the message doesn't get > stored and consequently > it will not be resent upon reconnection of the other > party. > > I suggest the following change: > Lines 432, 433 should be: > > 432 messageString = message.toString(); > 433 if ( isLoggedOn() ) result = > 434 send( messageString ); > > Best regards, and once again thank you for this > excellent piece of code > > Vitor Castro > > > > ------------------------------------------------------- > This SF.Net email is sponsored by: INetU > Attention Web Developers & Consultants: Become An > INetU Hosting Partner. > Refer Dedicated Servers. We Manage Them. You Get 10% > Monthly Commission! > INetU Dedicated Managed Hosting > http://www.inetu.net/partner/index.php > _______________________________________________ > Quickfix-developers mailing list > Qui...@li... > https://lists.sourceforge.net/lists/listinfo/quickfix-developers __________________________________ Do you Yahoo!? SBC Yahoo! DSL - Now only $29.95 per month! http://sbc.yahoo.com |