Cleaned up compiler warnings for Borland 5.5 compile.

This commit is contained in:
skarg
2008-03-08 15:09:14 +00:00
parent a3e2d61f56
commit cff20d7669
5 changed files with 14 additions and 6 deletions
+3 -1
View File
@@ -103,6 +103,8 @@ static int cov_encode_subscription(
int apdu_len = 0; int apdu_len = 0;
BACNET_OCTET_STRING octet_string; BACNET_OCTET_STRING octet_string;
/* FIXME: unused parameter */
max_apdu = max_apdu;
/* Recipient [0] BACnetRecipientProcess - opening */ /* Recipient [0] BACnetRecipientProcess - opening */
len = encode_opening_tag(&apdu[apdu_len], 0); len = encode_opening_tag(&apdu[apdu_len], 0);
apdu_len += len; apdu_len += len;
@@ -385,7 +387,7 @@ void handler_cov_task(
uint32_t elapsed_seconds) uint32_t elapsed_seconds)
{ {
int index; int index;
int lifetime_seconds; uint32_t lifetime_seconds;
BACNET_OBJECT_ID object_id; BACNET_OBJECT_ID object_id;
bool status = false; bool status = false;
+1 -1
View File
@@ -47,7 +47,7 @@ extern "C" {
#if defined(BBMD_ENABLED) && BBMD_ENABLED #if defined(BBMD_ENABLED) && BBMD_ENABLED
void bvlc_maintenance_timer( void bvlc_maintenance_timer(
unsigned seconds); time_t seconds);
#else #else
#define bvlc_maintenance_timer(x) #define bvlc_maintenance_timer(x)
#endif #endif
+3
View File
@@ -330,6 +330,9 @@ bool dlmstp_compare_data_expecting_reply(
struct DER_compare_t request; struct DER_compare_t request;
struct DER_compare_t reply; struct DER_compare_t reply;
/* unused parameters */
request_pdu_len = request_pdu_len;
reply_pdu_len = reply_pdu_len;
/* decode the request data */ /* decode the request data */
request.address.mac[0] = src_address; request.address.mac[0] = src_address;
request.address.mac_len = 1; request.address.mac_len = 1;
+2 -2
View File
@@ -206,7 +206,7 @@ uint16_t bip_receive(
struct timeval select_timeout; struct timeval select_timeout;
struct sockaddr_in sin = { -1 }; struct sockaddr_in sin = { -1 };
socklen_t sin_len = sizeof(sin); socklen_t sin_len = sizeof(sin);
unsigned i = 0; uint16_t i = 0;
/* Make sure the socket is open */ /* Make sure the socket is open */
if (BIP_Socket < 0) if (BIP_Socket < 0)
@@ -250,7 +250,7 @@ uint16_t bip_receive(
(pdu[1] == BVLC_ORIGINAL_BROADCAST_NPDU)) { (pdu[1] == BVLC_ORIGINAL_BROADCAST_NPDU)) {
/* ignore messages from me */ /* ignore messages from me */
if ((sin.sin_addr.s_addr == htonl(BIP_Address.s_addr)) && if ((sin.sin_addr.s_addr == htonl(BIP_Address.s_addr)) &&
(sin.sin_port == htonl(BIP_Port))) { (sin.sin_port == htons(BIP_Port))) {
pdu_len = 0; pdu_len = 0;
#if PRINT_ENABLED #if PRINT_ENABLED
fprintf(stderr,"BIP: src is me. Discarded!\n"); fprintf(stderr,"BIP: src is me. Discarded!\n");
+5 -2
View File
@@ -92,7 +92,7 @@ static struct sockaddr_in Remote_BBMD;
#if defined(BBMD_ENABLED) && BBMD_ENABLED #if defined(BBMD_ENABLED) && BBMD_ENABLED
void bvlc_maintenance_timer( void bvlc_maintenance_timer(
unsigned seconds) time_t seconds)
{ {
unsigned i = 0; unsigned i = 0;
@@ -711,6 +711,9 @@ void bvlc_broadcast_forward_npdu(
int mtu_len = 0; int mtu_len = 0;
struct sockaddr_in bvlc_dest; struct sockaddr_in bvlc_dest;
/* FIXME: unused parameter */
sin = sin;
/* load the buffer for transmit */
mtu[0] = BVLL_TYPE_BACNET_IP; mtu[0] = BVLL_TYPE_BACNET_IP;
mtu[1] = BVLC_ORIGINAL_BROADCAST_NPDU; mtu[1] = BVLC_ORIGINAL_BROADCAST_NPDU;
bvlc_dest.sin_addr.s_addr = htonl(bip_get_broadcast_addr()); bvlc_dest.sin_addr.s_addr = htonl(bip_get_broadcast_addr());
@@ -841,7 +844,7 @@ uint16_t bvlc_receive(
int function_type = 0; int function_type = 0;
int received_bytes = 0; int received_bytes = 0;
uint16_t result_code = 0; uint16_t result_code = 0;
unsigned i = 0; uint16_t i = 0;
bool status = false; bool status = false;
uint16_t time_to_live = 0; uint16_t time_to_live = 0;