memcpy function is used for copy to dst from src with size:
Code:
memcpy(dst, src, size)
If msg structure was defined as follow:
Code:
struct msg{
       char data[100];
       int dsize;
}
and buf defined as follow:
Code:
struct buf{
       char *data;
       int len;
}
Now if i run below command:
Code:
memcpy(msg->data+msg->dsize, buf->data, buf->len)
Does copy buf->data to msg->data? If yes, what is effect of msg->dsize?

I saw this in a C project.