Skip to content
Discussion options

You must be logged in to vote

The issue has been resolved. It was caused by my misuse of DynamicData::_ref_type in DynamicPubSubType::serialize().
the right way is :

 uint32_t serialized_size = dyn_pub_sub_type_->calculate_serialized_size(
      &dyn_data, XCDR_DATA_REPRESENTATION);
  eprosima::fastdds::rtps::SerializedPayload_t serialized_payload(
      serialized_size);
  dyn_pub_sub_type_->serialize(&dyn_data, serialized_payload,
                               XCDR_DATA_REPRESENTATION);

Replies: 4 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by com-server-ap
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant