Commit c9887a6b authored by Pekka Pessi's avatar Pekka Pessi

msg_header_copy.c: unobfuscated msg_default_dup_one()

Ignore-this: 1fda1941baecad1f6397de453e606f1c

Coverity issue.

darcs-hash:20090513161827-db55f-77b4dfbe3dac484b9ba403fcd14b3c70ef0e1b6d.gz
parent 9e0cdfab
......@@ -346,9 +346,9 @@ char *msg_default_dup_one(msg_header_t *h,
char *b,
isize_t xtra)
{
memcpy(&h->sh_header_next[1],
&src->sh_header_next[1],
h->sh_class->hc_size - offsetof(msg_header_t, sh_header_next[1]));
size_t skip = offsetof(msg_numeric_t, x_value); /* Skip common part */
memcpy((char *)h + skip, (char const *)src + skip, h->sh_class->hc_size - skip);
return b;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment