Refinitiv / Real-Time-SDK

Other
184 stars 129 forks source link

Fatal Error: oIter->_curBufPtr, Invalid iterator use - check buffer #163

Closed DuncanSands closed 1 year ago

DuncanSands commented 3 years ago

If I build with assertions enabled, then every few weeks I hit this Fatal Error: oIter->_curBufPtr, Invalid iterator use - check buffer (file .../Eta/Impl/Codec/fieldListDecoder.c, line 34) when receiving market data (Elektron as a service). This assertion is

RSSL_API RsslRet rsslDecodeFieldList(
                                RsslDecodeIterator              *oIter,
                                RsslFieldList                   *oFieldList,
                                RsslLocalFieldSetDefDb  *iLocalSetDb )
{
        char            *position;
        char            *_endBufPtr;
        RsslDecodingLevel *_levelInfo;

        RSSL_ASSERT(oIter, Invalid parameters or parameters passed in as NULL);
        RSSL_ASSERT(oIter->_curBufPtr, Invalid iterator use - check buffer); // <== THIS LINE

Backtrace:

Eta/Impl/Codec/rtr/retmacros.h:27 Ema/Src/Access/Impl/FieldListDecoder.cpp:283 Ema/Src/Access/Impl/StaticDecoder.cpp:106 Ema/Src/Access/Impl/UpdateMsgDecoder.cpp:54 Ema/Src/Access/Impl/StaticDecoder.cpp:69 Ema/Src/Access/Impl/ItemCallbackClient.cpp:3222 Eta/Impl/Reactor/rsslReactor.c:3630 Eta/Impl/Reactor/rsslReactor.c:4438 Eta/Impl/Reactor/rsslReactor.c:4468 Eta/Impl/Reactor/Watchlist/wlItem.c:1637 Eta/Impl/Reactor/Watchlist/rsslWatchlistImpl.c:2233 Eta/Impl/Reactor/Watchlist/rsslWatchlistImpl.c:1537 Eta/Impl/Reactor/rsslReactor.c:4892 Eta/Impl/Reactor/rsslReactor.c:1968

Version is RTSDK-1.5.1.L1.linux.rrg. This happened with earlier versions too. Any ideas? An instance of the same program with assertions disabled running in parallel on the same data seems to work fine, no crash or odd output (that I've noticed) at this time, so perhaps the assertion is buggy?

fogol commented 3 years ago

@DuncanSands Thank you for bringing this to our attention. I have raised a JIRA to investigate this, and it will be fixed in further releases.

MitchellKato commented 3 years ago

@DuncanSands If possible, can you please attempt to provide a pcap or other wire trace of the message?

Thanks!

DuncanSands commented 3 years ago

I'm running a packet capture. It may take a few weeks or months for the issue to show.

DuncanSands commented 3 years ago

I have a packet capture. Probably it is better not to make it available for public download. Shall I send you a download link privately?

DuncanSands commented 1 year ago

I haven't seen this since upgrading to RTSDK-2.1.1.L1.