fixed compiler warnings.
This commit is contained in:
@@ -108,9 +108,9 @@ void _processSendStatsMessage(AQHOMED *aqh, const GWEN_MSG *nodeMsg)
|
||||
double collisionsPercentage=0.0;
|
||||
double busyPercentage=0.0;
|
||||
|
||||
packetsOut=(double) packetsOutInt;
|
||||
collisions=(double)AQH_SendStatsMsg_GetCollisions(nodeMsg);
|
||||
busy=(double)AQH_SendStatsMsg_GetBusyErrors(nodeMsg);
|
||||
packetsOut=/*(double)*/ packetsOutInt;
|
||||
collisions=/*(double)*/ AQH_SendStatsMsg_GetCollisions(nodeMsg);
|
||||
busy=/*(double)*/ AQH_SendStatsMsg_GetBusyErrors(nodeMsg);
|
||||
|
||||
collisionsPercentage=collisions*100.0/packetsOut;
|
||||
busyPercentage=busy*100.0/packetsOut;
|
||||
@@ -136,9 +136,9 @@ void _processRecvStatsMessage(AQHOMED *aqh, const GWEN_MSG *nodeMsg)
|
||||
double crcErrorsPercentage=0.0;
|
||||
double ioErrorsPercentage=0.0;
|
||||
|
||||
packetsIn=(double) packetsInInt;
|
||||
crcErrors=(double)AQH_RecvStatsMsg_GetCrcErrors(nodeMsg);
|
||||
ioErrors=(double)AQH_RecvStatsMsg_GetIoErrors(nodeMsg);
|
||||
packetsIn=/*(double)*/ packetsInInt;
|
||||
crcErrors=/*(double)*/AQH_RecvStatsMsg_GetCrcErrors(nodeMsg);
|
||||
ioErrors=/*(double)*/AQH_RecvStatsMsg_GetIoErrors(nodeMsg);
|
||||
|
||||
crcErrorsPercentage=crcErrors*100.0/packetsIn;
|
||||
ioErrorsPercentage=ioErrors*100.0/packetsIn;
|
||||
@@ -155,7 +155,7 @@ void _processRecvStatsMessage(AQHOMED *aqh, const GWEN_MSG *nodeMsg)
|
||||
|
||||
void _publishInt(AQHOMED *aqh, uint32_t uid, int valueId, const char *valueUnits, const char *valuePath, int v)
|
||||
{
|
||||
_publishDouble(aqh, uid, valueId, valueUnits, valuePath, (double) v);
|
||||
_publishDouble(aqh, uid, valueId, valueUnits, valuePath, /*(double)*/ v);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -213,9 +213,11 @@ void _awaitAndPrintChanges(GWEN_MSG_ENDPOINT *epTcp, int timeoutInSeconds, const
|
||||
}
|
||||
if (timeoutInSeconds) {
|
||||
time_t now;
|
||||
double delta;
|
||||
|
||||
now=time(NULL);
|
||||
if ((int)(difftime(now, tStart))>=timeoutInSeconds) {
|
||||
delta=difftime(now, tStart);
|
||||
if ((int)delta>=timeoutInSeconds) {
|
||||
DBG_INFO(NULL, "Timeout");
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user