Skip to content

[rosserial_client] fix deserialization for nested array - #633

Open
sugikazu75 wants to merge 2 commits into
ros-drivers:noetic-develfrom
sugikazu75:PR/rosserial_client/library/nested_array
Open

sugikazu75 wants to merge 2 commits into
ros-drivers:noetic-develfrom
sugikazu75:PR/rosserial_client/library/nested_array

Conversation

@sugikazu75

@sugikazu75 sugikazu75 commented Oct 3, 2025

Copy link
Copy Markdown

This patch enables to receive array of array in microcontroller correctly by fixing deserialization fofr message.

When sending an array of arrays to the microcontroller, accessing it yielded the same value even though it should have sent different values.
This is caused by a deserialization error resulting in the same pointer being referenced.
A similar report can be found at #314 (comment).

I fixed the part that deserializes messages. I deserialized each element composing the array directly to prevent sharing pointers.

@sugikazu75

Copy link
Copy Markdown
Author

I made a repository to test this phenominon https://github.com/sugikazu75/rosserial_nested_array

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant