- GNUNET_assert (xc_size <= UINT16_MAX);
- msize = (uint16_t) xc_size +
- sizeof (struct GNUNET_TESTBED_PeerReconfigureMessage);
- msg = GNUNET_realloc (xconfig, msize);
- (void) memmove (&msg[1], msg, xc_size);
- msg->header.size = htons (msize);
- msg->header.type = htons (GNUNET_MESSAGE_TYPE_TESTBED_RECONFIGURE_PEER);
+ GNUNET_assert (xc_size < UINT16_MAX - sizeof(*msg));
+ env = GNUNET_MQ_msg_extra (msg,
+ xc_size,
+ GNUNET_MESSAGE_TYPE_TESTBED_RECONFIGURE_PEER);