Login Page - Create Account

DTC Protocol Discussion Forum


Date/Time: Tue, 13 Nov 2018 05:36:52 +0000


Real LogonResponse data lenght and s_LogonResponse from headers lengths discrepance

Support Request:
[2017-12-20 19:59:47]
User977859 - Posts: 1
Hello,
I found following: DTC server return me Logon Response with size = 256. (Fixed binary enc., logon success.) In the same time when we sum all data lenghts from s_LogonResponse structure (DTCProtocol.h) then get 262 bytes.
How is it possible?

NB: string ServerName is converted from response's byte[] successfully to "SC DTC Server", but string SymbolExchangeDelimiter - is not - it has value "\u0001\0\0\u0001". Is the length of ServerName in the file DTCProtocol.h specified correctly?

Correct me if I am wrong...
Thank you.

struct s_LogonResponse
  {
    uint16_t Size;
    uint16_t Type;
    int32_t ProtocolVersion;
    LogonStatusEnum Result;
    char ResultText[TEXT_DESCRIPTION_LENGTH]; //96
    char ReconnectAddress[64];
    int32_t Integer_1;
    char ServerName[60];
    uint8_t MarketDepthUpdatesBestBidAndAsk;
    uint8_t TradingIsSupported;
    uint8_t OCOOrdersSupported;
    uint8_t OrderCancelReplaceSupported;
    char SymbolExchangeDelimiter[SYMBOL_EXCHANGE_DELIMITER_LENGTH]; //4
    uint8_t SecurityDefinitionsSupported;
    uint8_t HistoricalPriceDataSupported;
    uint8_t ResubscribeWhenMarketDataFeedAvailable;
    uint8_t MarketDepthIsSupported;
    uint8_t OneHistoricalPriceDataRequestPerConnection;
    uint8_t BracketOrdersSupported;
    uint8_t UseIntegerPriceOrderMessages;
    uint8_t UsesMultiplePositionsPerSymbolAndTradeAccount;
    uint8_t MarketDataSupported;
[2017-12-23 09:08:42]
Andreas - Posts: 366
SC support,

any opinion on this?

i am buffled as well..

thanks,
Andreas
[2017-12-23 22:41:07]
DTC Engineering - Posts: 270
With #pragma pack(8), the compiler reports the size as:

DTC::s_LogonResponse size: 256

Here is the current header file:
http://dtcprotocol.org/DTC_Files/DTCProtocol.h

We cannot say anything further on this.
Date Time Of Last Edit: 2017-12-23 22:45:05

To post a message in this thread, you need to login with your Sierra Chart account:

Login


Login Page - Create Account