Fixed indent script, and indented files.

This commit is contained in:
skarg
2010-07-19 23:19:54 +00:00
parent c0d63a1ed0
commit 6c9ef7211d
69 changed files with 681 additions and 627 deletions
+16 -14
View File
@@ -48,7 +48,8 @@ static uint16_t BBMD_Timer_Seconds;
* - BACNET_BBMD_TIMETOLIVE - 0..65535 seconds, defaults to 60000
* - BACNET_BBMD_ADDRESS - dotted IPv4 address
*/
void dlenv_register_as_foreign_device(void)
void dlenv_register_as_foreign_device(
void)
{
#if defined(BACDL_BIP) && BBMD_ENABLED
char *pEnv = NULL;
@@ -79,8 +80,8 @@ void dlenv_register_as_foreign_device(void)
fprintf(stderr,
"Registering with BBMD at %s:%ld for %ld seconds\n",
inet_ntoa(addr), bbmd_port, bbmd_timetolive_seconds);
bvlc_register_with_bbmd(bbmd_address, (uint16_t)bbmd_port,
(uint16_t)bbmd_timetolive_seconds);
bvlc_register_with_bbmd(bbmd_address, (uint16_t) bbmd_port,
(uint16_t) bbmd_timetolive_seconds);
BBMD_Timer_Seconds = bbmd_timetolive_seconds;
}
}
@@ -92,7 +93,8 @@ void dlenv_register_as_foreign_device(void)
*
* Call this function to renew Foreign Device Registration
*/
void dlenv_maintenance_timer(uint16_t elapsed_seconds)
void dlenv_maintenance_timer(
uint16_t elapsed_seconds)
{
if (BBMD_Timer_Seconds) {
if (BBMD_Timer_Seconds <= elapsed_seconds) {
@@ -153,16 +155,16 @@ void dlenv_init(
#endif
pEnv = getenv("BACNET_IP_PORT");
if (pEnv) {
bip_set_port((uint16_t)strtol(pEnv, NULL, 0));
bip_set_port((uint16_t) strtol(pEnv, NULL, 0));
} else {
/* BIP_Port is statically initialized to 0xBAC0,
* so if it is different, then it was programmatically altered,
* and we shouldn't just stomp on it here.
* Unless it is set below 1024, since:
* "The range for well-known ports managed by the IANA is 0-1023."
*/
if ( bip_get_port() < 1024 )
bip_set_port(0xBAC0);
/* BIP_Port is statically initialized to 0xBAC0,
* so if it is different, then it was programmatically altered,
* and we shouldn't just stomp on it here.
* Unless it is set below 1024, since:
* "The range for well-known ports managed by the IANA is 0-1023."
*/
if (bip_get_port() < 1024)
bip_set_port(0xBAC0);
}
#elif defined(BACDL_MSTP)
pEnv = getenv("BACNET_MAX_INFO_FRAMES");
@@ -192,7 +194,7 @@ void dlenv_init(
#endif
pEnv = getenv("BACNET_APDU_TIMEOUT");
if (pEnv) {
apdu_timeout_set((uint16_t)strtol(pEnv, NULL, 0));
apdu_timeout_set((uint16_t) strtol(pEnv, NULL, 0));
fprintf(stderr, "BACNET_APDU_TIMEOUT=%s\r\n", pEnv);
} else {
#if defined(BACDL_MSTP)