cleaned up some warnings.
This commit is contained in:
@@ -6,10 +6,10 @@ BASEDIR = .
|
||||
#CFLAGS = -Wall -I. -O2 -g
|
||||
# Note: you can strip out symbols using the strip command
|
||||
# to get an idea of how big the compile really is.
|
||||
#CFLAGS = -Wall -I. -Iports/linux -g -DBACDL_ETHERNET=1
|
||||
#CFLAGS = -Wall -I. -Iports/linux -g -DBACDL_ARCNET=1
|
||||
#CFLAGS = -Wall -I. -Iports/linux -g -DBACDL_MSTP=1
|
||||
CFLAGS = -Wall -I. -Iports/linux -g -DBACDL_BIP=1
|
||||
#CFLAGS = -Wall -I. -Iports/linux -g -DBACFILE=1 -DBACDL_ETHERNET=1
|
||||
#CFLAGS = -Wall -I. -Iports/linux -g -DBACFILE=1 -DBACDL_ARCNET=1
|
||||
#CFLAGS = -Wall -I. -Iports/linux -g -DBACFILE=1 -DBACDL_MSTP=1
|
||||
CFLAGS = -Wall -I. -Iports/linux -g -DBACFILE=1 -DBACDL_BIP=1
|
||||
|
||||
SRCS = ports/linux/main.c \
|
||||
ports/linux/ethernet.c \
|
||||
@@ -23,6 +23,7 @@ SRCS = ports/linux/main.c \
|
||||
whois.c \
|
||||
iam.c \
|
||||
rp.c \
|
||||
rpm.c \
|
||||
wp.c \
|
||||
tsm.c \
|
||||
datalink.c \
|
||||
|
||||
@@ -1567,10 +1567,10 @@ void testBACDCodeOctetString(Test * pTest)
|
||||
uint8_t tag_number = 0;
|
||||
uint32_t len_value = 0;
|
||||
|
||||
apdu_len = encode_tagged_octet_string(&array[0], &test_string0[0], 0);
|
||||
apdu_len = encode_tagged_octet_string(&array[0], (uint8_t *)&test_string0[0], 0);
|
||||
len = decode_tag_number_and_value(&array[0], &tag_number, &len_value);
|
||||
len += decode_octet_string(&array[len], len_value,
|
||||
&decoded_string[0], sizeof(decoded_string));
|
||||
(uint8_t *)&decoded_string[0], sizeof(decoded_string));
|
||||
ct_test(pTest, apdu_len == len);
|
||||
ct_test(pTest, memcmp(&test_string0[0], &decoded_string[0],
|
||||
len_value) == 0);
|
||||
@@ -1578,11 +1578,11 @@ void testBACDCodeOctetString(Test * pTest)
|
||||
test_string[i] = '0' + (i % 10);
|
||||
apdu_len =
|
||||
encode_tagged_octet_string(&encoded_array[0],
|
||||
&test_string[0], i);
|
||||
(uint8_t *)&test_string[0], i);
|
||||
len = decode_tag_number_and_value(&encoded_array[0],
|
||||
&tag_number, &len_value);
|
||||
len += decode_octet_string(&encoded_array[len], len_value,
|
||||
&decoded_string[0], sizeof(decoded_string));
|
||||
(uint8_t *)&decoded_string[0], sizeof(decoded_string));
|
||||
if (apdu_len != len) {
|
||||
printf("test octet string=#%d\n", i);
|
||||
}
|
||||
|
||||
+1
-1
@@ -217,7 +217,7 @@ uint16_t bip_receive(
|
||||
int max;
|
||||
struct timeval select_timeout;
|
||||
struct sockaddr_in sin = {-1};
|
||||
int sin_len = sizeof(sin);
|
||||
size_t sin_len = sizeof(sin);
|
||||
|
||||
/* Make sure the socket is open */
|
||||
if (BIP_Socket < 0)
|
||||
|
||||
Reference in New Issue
Block a user