osaf/libs/core/include/mds_papi.h | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-)
After the changes of MDS enhancement ticket #1522, MDS TCP application getting segmentation if application trying to send messge size > 65535 Bug : MDS:TCP code changes included the node name as a part MDS TCP message header, but TCP fragment size macro was not tuned according to new MDS user data size Fix : TCP fragment size macro need to be tuned according to new MDS HDR size need to less HOST_NAME_MAX size from default MDS_DIRECT_BUF_MAXSIZE) diff --git a/osaf/libs/core/include/mds_papi.h b/osaf/libs/core/include/mds_papi.h --- a/osaf/libs/core/include/mds_papi.h +++ b/osaf/libs/core/include/mds_papi.h @@ -223,8 +223,9 @@ extern const char *get_svc_names(int svc #define NCSMDS_MAX_VDEST 32767 #define NCSMDS_MAX_SVCS 1023 -/* Maximum size of the buffer used with MDS_DIRECT_SEND (no encoding) */ -#define MDS_DIRECT_BUF_MAXSIZE (65535 - 56) +/* Maximum size of the buffer used with MDS_DIRECT_SEND (no encoding) + (2^16 - (SUM_MDS_HDR_PLUS_MDTM_HDR_PLUS_LEN_TCP + HOST_NAME_MAX)) */ +#define MDS_DIRECT_BUF_MAXSIZE (65535 - (57 + HOST_NAME_MAX)) typedef uint8_t *MDS_DIRECT_BUFF; ------------------------------------------------------------------------------ Transform Data into Opportunity. Accelerate data analysis in your applications with Intel Data Analytics Acceleration Library. Click to learn more. http://makebettercode.com/inteldaal-eval _______________________________________________ Opensaf-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/opensaf-devel
