diff options
author | Javier Garcia <javier.garcia@voltanet.io> | 2021-03-20 22:21:09 +0100 |
---|---|---|
committer | Javier Garcia <javier.garcia@voltanet.io> | 2021-03-20 22:21:09 +0100 |
commit | 7ed8c4b1fd2cd46864271e44a9778caa31d367fd (patch) | |
tree | 3b11f0c2123b57fee1cc7cf9ef0a21268decf7fe /pceplib/pcep_msg_tlvs.c | |
parent | Merge pull request #8232 from reubendowle/fixes/nhrp-ipsec-issues (diff) | |
download | frr-7ed8c4b1fd2cd46864271e44a9778caa31d367fd.tar.xz frr-7ed8c4b1fd2cd46864271e44a9778caa31d367fd.zip |
pceplib: Fixing coverity messages.
Signed-off-by: Javier Garcia <javier.garcia@voltanet.io>
Diffstat (limited to 'pceplib/pcep_msg_tlvs.c')
-rw-r--r-- | pceplib/pcep_msg_tlvs.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pceplib/pcep_msg_tlvs.c b/pceplib/pcep_msg_tlvs.c index 890da9517..9c84e71ee 100644 --- a/pceplib/pcep_msg_tlvs.c +++ b/pceplib/pcep_msg_tlvs.c @@ -401,7 +401,7 @@ pcep_tlv_create_srpag_pol_name(const char *pol_name, uint16_t pol_name_length) (normalize_pcep_tlv_length(pol_name_length) > MAX_POLICY_NAME) ? MAX_POLICY_NAME : pol_name_length; - memcpy(tlv->name, pol_name, pol_name_length); + memcpy(tlv->name, pol_name, length); tlv->name_length = length; return tlv; @@ -456,7 +456,7 @@ pcep_tlv_create_tlv_arbitrary(const char *data, uint16_t data_length, uint16_t length = (data_length > MAX_ARBITRARY_SIZE) ? MAX_ARBITRARY_SIZE : data_length; - memcpy(tlv->data, data, data_length); + memcpy(tlv->data, data, length); tlv->data_length = length; tlv->arbitraty_type = tlv_id; |