aqhome, aqhome-apps: cleanup, removed unneeded files.
This commit is contained in:
@@ -109,10 +109,10 @@ static int _handleSignal(AQH_OBJECT *o, uint32_t slotId, AQH_OBJECT *senderObjec
|
||||
static int _handleBrokerDown(AQH_MQTTLOG_SERVER *xo);
|
||||
static int _handleMqttDown(AQH_MQTTLOG_SERVER *xo);
|
||||
|
||||
static void _handleMsgFromBroker(AQH_OBJECT *o, AQH_OBJECT *ep, const AQH_MESSAGE *msg);
|
||||
static void _handleMsgFromBroker(AQH_OBJECT *o, const AQH_MESSAGE *msg);
|
||||
|
||||
static void _handleMsgFromMqtt(AQH_OBJECT *o, AQH_OBJECT *ep, const AQH_MESSAGE *msg);
|
||||
static void _handleMqttMsgPingRsp(AQH_OBJECT *o, AQH_OBJECT *ep, const AQH_MESSAGE *msg);
|
||||
static void _handleMqttMsgPingRsp(void);
|
||||
|
||||
static int _createPidFile(const char *pidFilename);
|
||||
static int _diffInSeconds(time_t t1, time_t t0);
|
||||
@@ -474,7 +474,7 @@ int _startBroker(AQH_OBJECT *o, AQH_MQTTLOG_SERVER *xo)
|
||||
DBG_ERROR(NULL, "Error connecting to broker: %d", rv);
|
||||
return (rv<0)?rv:GWEN_ERROR_PERMISSIONS;
|
||||
}
|
||||
DBG_NOTICE(NULL, "Connected to broker at %s:%d", xo->brokerAddress, xo->brokerPort);
|
||||
DBG_NOTICE(NULL, "Fully connected to broker at %s:%d", xo->brokerAddress, xo->brokerPort);
|
||||
return 0;
|
||||
}
|
||||
else {
|
||||
@@ -658,7 +658,7 @@ void AQH_MqttLogServer_HandleBrokerMsgs(AQH_OBJECT *o)
|
||||
|
||||
while( (msg=AQH_Endpoint_GetNextMsgIn(xo->brokerEndpoint)) ) {
|
||||
AQH_Message_SetObject(msg, xo->brokerEndpoint);
|
||||
_handleMsgFromBroker(o, xo->brokerEndpoint, msg);
|
||||
_handleMsgFromBroker(o, msg);
|
||||
AQH_Message_free(msg);
|
||||
}
|
||||
}
|
||||
@@ -666,7 +666,7 @@ void AQH_MqttLogServer_HandleBrokerMsgs(AQH_OBJECT *o)
|
||||
|
||||
|
||||
|
||||
void _handleMsgFromBroker(AQH_OBJECT *o, AQH_OBJECT *ep, const AQH_MESSAGE *msg)
|
||||
void _handleMsgFromBroker(AQH_OBJECT *o, const AQH_MESSAGE *msg)
|
||||
{
|
||||
GWEN_TAG16_LIST *tagList;
|
||||
|
||||
@@ -762,14 +762,14 @@ void _handleMsgFromMqtt(AQH_OBJECT *o, AQH_OBJECT *ep, const AQH_MESSAGE *msg)
|
||||
code=AQH_MqttMessage_GetTypeAndFlags(msg);
|
||||
switch(code & 0xf0) {
|
||||
case (AQH_MQTTMSG_MSGTYPE_PUBLISH & 0xf0): AQH_MqttLogServer_HandlePublishMsg(o, ep, msg); break;
|
||||
case (AQH_MQTTMSG_MSGTYPE_PINGRESP & 0xf0): _handleMqttMsgPingRsp(o, ep, msg); break;
|
||||
case (AQH_MQTTMSG_MSGTYPE_PINGRESP & 0xf0): _handleMqttMsgPingRsp(); break;
|
||||
default: break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
void _handleMqttMsgPingRsp(AQH_OBJECT *o, AQH_OBJECT *ep, const AQH_MESSAGE *msg)
|
||||
void _handleMqttMsgPingRsp(void)
|
||||
{
|
||||
DBG_INFO(NULL, "PING response received");
|
||||
}
|
||||
@@ -962,8 +962,9 @@ void AQH_MqttLogServer_LoadRuntimeDeviceFiles(AQH_OBJECT *o)
|
||||
|
||||
DBG_INFO(NULL, "Loading registered devices from file \"%s\"", xo->deviceFile);
|
||||
deviceList=AQH_MqttLogServer_ReadDeviceFile(o, xo->deviceFile);
|
||||
if (deviceList)
|
||||
AQH_MqttLogServer_SetRegisteredDeviceList(o, deviceList);
|
||||
if (deviceList==NULL)
|
||||
deviceList=AQHMQTT_Device_List_new();
|
||||
AQH_MqttLogServer_SetRegisteredDeviceList(o, deviceList);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -999,7 +1000,7 @@ int AQH_MqttLogServer_SaveRuntimeDeviceFiles(AQH_OBJECT *o)
|
||||
* xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
||||
*/
|
||||
|
||||
int _handleSignal(AQH_OBJECT *o, uint32_t slotId, AQH_OBJECT *senderObject, GWEN_UNUSED int param1, void *param2)
|
||||
int _handleSignal(AQH_OBJECT *o, uint32_t slotId, GWEN_UNUSED AQH_OBJECT *senderObject, GWEN_UNUSED int param1, GWEN_UNUSED void *param2)
|
||||
{
|
||||
AQH_MQTTLOG_SERVER *xo;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user