summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2011-01-14 19:21:01 +0100
committerHolger Hans Peter Freyther <zecke@selfish.org>2011-01-14 19:21:01 +0100
commit5dd47222d224cc906a2606333f036aa1b51524df (patch)
tree3920ac4373476b368c7bb4bebbf45a62f17fc611
parentaa914ef127f180ab2868a7a1a31b0a4aa92ef71c (diff)
m2ua: Attempt to use a memcpy... maybe this is fixing a segfault
This is a bit of exploring why this could fail...
-rw-r--r--src/m2ua_msg.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/m2ua_msg.c b/src/m2ua_msg.c
index 99f7a0c..354e6d2 100644
--- a/src/m2ua_msg.c
+++ b/src/m2ua_msg.c
@@ -151,7 +151,7 @@ struct msgb *m2ua_to_msg(struct m2ua_msg *m2ua)
msg->l2h = msgb_put(msg, sizeof(*hdr));
hdr = (struct m2ua_common_hdr *) msg->l2h;
- *hdr = m2ua->hdr;
+ memcpy(hdr, &m2ua->hdr, sizeof(*hdr));
/* make sure that is right */
hdr->version = M2UA_VERSION;