oai_asn1.h: const-correctness/signal input parameter

This commit is contained in:
Robert Schmidt
2024-02-03 11:24:41 +01:00
parent 52bfd463de
commit ba5c34c1f6
+4 -4
View File
@@ -32,7 +32,7 @@
*\param[in] pointer to the BIT_STRING_t object.
*\return the extracted value.
*/
static inline uint8_t BIT_STRING_to_uint8(BIT_STRING_t *asn) {
static inline uint8_t BIT_STRING_to_uint8(const BIT_STRING_t *asn) {
DevCheck ((asn->size == 1), asn->size, 0, 0);
return asn->buf[0] >> asn->bits_unused;
@@ -43,7 +43,7 @@ static inline uint8_t BIT_STRING_to_uint8(BIT_STRING_t *asn) {
*\param[in] pointer to the BIT_STRING_t object.
*\return the extracted value.
*/
static inline uint16_t BIT_STRING_to_uint16(BIT_STRING_t *asn) {
static inline uint16_t BIT_STRING_to_uint16(const BIT_STRING_t *asn) {
uint16_t result = 0;
int index = 0;
@@ -69,7 +69,7 @@ static inline uint16_t BIT_STRING_to_uint16(BIT_STRING_t *asn) {
*\param[in] pointer to the BIT_STRING_t object.
*\return the extracted value.
*/
static inline uint32_t BIT_STRING_to_uint32(BIT_STRING_t *asn) {
static inline uint32_t BIT_STRING_to_uint32(const BIT_STRING_t *asn) {
uint32_t result = 0;
size_t index;
@@ -91,7 +91,7 @@ static inline uint32_t BIT_STRING_to_uint32(BIT_STRING_t *asn) {
*\param[in] pointer to the BIT_STRING_t object.
*\return the extracted value.
*/
static inline uint64_t BIT_STRING_to_uint64(BIT_STRING_t *asn) {
static inline uint64_t BIT_STRING_to_uint64(const BIT_STRING_t *asn) {
uint64_t result = 0;
size_t index;
int shift;