Clone chunk_t parameters in create function

This commit is contained in:
Sansar Choinyambuu
2011-11-28 14:34:20 +01:00
committed by Andreas Steffen
parent c10867f40b
commit 2f229f10b1
2 changed files with 4 additions and 4 deletions
@@ -231,8 +231,8 @@ pa_tnc_attr_t *tcg_pts_attr_dh_nonce_finish_create(u_int8_t nonce_len,
.type = TCG_PTS_DH_NONCE_FINISH,
.nonce_len = nonce_len,
.hash_algo = hash_algo,
.initiator_nonce = initiator_nonce,
.initiator_pub_val = initiator_pub_val,
.initiator_nonce = chunk_clone(initiator_nonce),
.initiator_pub_val = chunk_clone(initiator_pub_val),
);
return &this->public.pa_tnc_attribute;
@@ -249,8 +249,8 @@ pa_tnc_attr_t *tcg_pts_attr_dh_nonce_params_resp_create(u_int8_t nonce_len,
.nonce_len = nonce_len,
.dh_group = dh_group,
.hash_algo_set = hash_algo_set,
.responder_nonce = responder_nonce,
.responder_pub_val = responder_pub_val,
.responder_nonce = chunk_clone(responder_nonce),
.responder_pub_val = chunk_clone(responder_pub_val),
);
return &this->public.pa_tnc_attribute;