Skip to content

Commit

Permalink
Return correct length for partnumber
Browse files Browse the repository at this point in the history
  • Loading branch information
aveenismail committed Aug 31, 2024
1 parent 56bd670 commit d0b7a8b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/yubihsm.c
Original file line number Diff line number Diff line change
Expand Up @@ -1385,7 +1385,7 @@ yh_rc yh_util_get_partnumber(yh_connector *connector, char *part_number,
}
memcpy(part_number, response, response_len);
part_number[response_len] = 0;
*part_number_len = response_len;
*part_number_len = response_len + 1;

return YHR_SUCCESS;
}
Expand Down

0 comments on commit d0b7a8b

Please sign in to comment.