문제

I am working on a project where I need to send over a certain IPC stack, (in my case, LCM), and the thing is I need to provide the IPC a variable length struct. I have

struct pack1 {int value1; int value2;};
struct pack2 {void *data; int data_size;}; 
//data won't always point to pack1 types

I have a pointer to pack2, and I need something like serialization, so I can send this pack2 over the network to another process.

Anyone knows how?

올바른 솔루션이 없습니다

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top