get rid of "const" warnings in nas_message.c

This commit is contained in:
Cedric Roux
2016-03-26 23:25:30 +01:00
parent ce0adf779b
commit 2cea2dbed9
+10 -10
View File
@@ -1016,10 +1016,10 @@ static int _nas_message_decrypt(
stream_cipher.count = count; stream_cipher.count = count;
stream_cipher.bearer = 0x00; //33.401 section 8.1.1 stream_cipher.bearer = 0x00; //33.401 section 8.1.1
stream_cipher.direction = direction; stream_cipher.direction = direction;
stream_cipher.message = src; stream_cipher.message = (unsigned char *)src;
/* length in bits */ /* length in bits */
stream_cipher.blength = length << 3; stream_cipher.blength = length << 3;
nas_stream_encrypt_eea1(&stream_cipher, dest); nas_stream_encrypt_eea1(&stream_cipher, (unsigned char *)dest);
/* Decode the first octet (security header type or EPS bearer identity, /* Decode the first octet (security header type or EPS bearer identity,
* and protocol discriminator) */ * and protocol discriminator) */
DECODE_U8(dest, *(uint8_t*)(&header), size); DECODE_U8(dest, *(uint8_t*)(&header), size);
@@ -1050,10 +1050,10 @@ static int _nas_message_decrypt(
stream_cipher.count = count; stream_cipher.count = count;
stream_cipher.bearer = 0x00; //33.401 section 8.1.1 stream_cipher.bearer = 0x00; //33.401 section 8.1.1
stream_cipher.direction = direction; stream_cipher.direction = direction;
stream_cipher.message = src; stream_cipher.message = (unsigned char *)src;
/* length in bits */ /* length in bits */
stream_cipher.blength = length << 3; stream_cipher.blength = length << 3;
nas_stream_encrypt_eea1(&stream_cipher, dest); nas_stream_encrypt_eea1(&stream_cipher, (unsigned char *)dest);
/* Decode the first octet (security header type or EPS bearer identity, /* Decode the first octet (security header type or EPS bearer identity,
* and protocol discriminator) */ * and protocol discriminator) */
DECODE_U8(dest, *(uint8_t*)(&header), size); DECODE_U8(dest, *(uint8_t*)(&header), size);
@@ -1178,10 +1178,10 @@ static int _nas_message_encrypt(
stream_cipher.count = count; stream_cipher.count = count;
stream_cipher.bearer = 0x00; //33.401 section 8.1.1 stream_cipher.bearer = 0x00; //33.401 section 8.1.1
stream_cipher.direction = direction; stream_cipher.direction = direction;
stream_cipher.message = src; stream_cipher.message = (unsigned char *)src;
/* length in bits */ /* length in bits */
stream_cipher.blength = length << 3; stream_cipher.blength = length << 3;
nas_stream_encrypt_eea1(&stream_cipher, dest); nas_stream_encrypt_eea1(&stream_cipher, (unsigned char *)dest);
LOG_FUNC_RETURN (length); LOG_FUNC_RETURN (length);
@@ -1209,10 +1209,10 @@ static int _nas_message_encrypt(
stream_cipher.count = count; stream_cipher.count = count;
stream_cipher.bearer = 0x00; //33.401 section 8.1.1 stream_cipher.bearer = 0x00; //33.401 section 8.1.1
stream_cipher.direction = direction; stream_cipher.direction = direction;
stream_cipher.message = src; stream_cipher.message = (unsigned char *)src;
/* length in bits */ /* length in bits */
stream_cipher.blength = length << 3; stream_cipher.blength = length << 3;
nas_stream_encrypt_eea2(&stream_cipher, dest); nas_stream_encrypt_eea2(&stream_cipher, (unsigned char *)dest);
LOG_FUNC_RETURN (length); LOG_FUNC_RETURN (length);
@@ -1344,7 +1344,7 @@ static uint32_t _nas_message_get_mac(
stream_cipher.count = count; stream_cipher.count = count;
stream_cipher.bearer = 0x00; //33.401 section 8.1.1 stream_cipher.bearer = 0x00; //33.401 section 8.1.1
stream_cipher.direction = direction; stream_cipher.direction = direction;
stream_cipher.message = buffer; stream_cipher.message = (unsigned char *)buffer;
/* length in bits */ /* length in bits */
stream_cipher.blength = length << 3; stream_cipher.blength = length << 3;
@@ -1390,7 +1390,7 @@ static uint32_t _nas_message_get_mac(
stream_cipher.count = count; stream_cipher.count = count;
stream_cipher.bearer = 0x00; //33.401 section 8.1.1 stream_cipher.bearer = 0x00; //33.401 section 8.1.1
stream_cipher.direction = direction; stream_cipher.direction = direction;
stream_cipher.message = buffer; stream_cipher.message = (unsigned char *)buffer;
/* length in bits */ /* length in bits */
stream_cipher.blength = length << 3; stream_cipher.blength = length << 3;