From 3094048e4b99f37830a3fd6fda2c04214d9799ac Mon Sep 17 00:00:00 2001 From: Martin Preuss Date: Tue, 25 Apr 2023 00:37:40 +0200 Subject: [PATCH] mqtt client: removed unused code. --- aqhome/mqtt/endpoint_mqttc.c | 30 ------------------------------ aqhome/mqtt/endpoint_mqttc_p.h | 1 - 2 files changed, 31 deletions(-) diff --git a/aqhome/mqtt/endpoint_mqttc.c b/aqhome/mqtt/endpoint_mqttc.c index 9a980cf..6804600 100644 --- a/aqhome/mqtt/endpoint_mqttc.c +++ b/aqhome/mqtt/endpoint_mqttc.c @@ -35,7 +35,6 @@ GWEN_INHERIT(GWEN_MSG_ENDPOINT, AQH_ENDPOINT_MQTTC) static void GWENHYWFAR_CB _freeData(void *bp, void *p); -//static void _run(GWEN_MSG_ENDPOINT *ep); static int _connect(GWEN_MSG_ENDPOINT *ep); static void _sendConnectMsg(GWEN_MSG_ENDPOINT *ep); static void _checkForConnAckMsg(GWEN_MSG_ENDPOINT *ep); @@ -71,7 +70,6 @@ GWEN_MSG_ENDPOINT *AQH_MqttClientEndpoint_new(const char *host, int port, const GWEN_MsgEndpoint_SetDefaultBufferSize(ep, GWEN_ENDPOINT_MQTTC_BUFFERSIZE); GWEN_MsgEndpoint_SetIsMsgCompleteFn(ep, _isMsgComplete); - //xep->previousRunFn=GWEN_MsgEndpoint_SetRunFn(ep, _run); GWEN_MsgEndpoint_SetProcessOutMsgFn(ep, _processOutMessage); xep->previousConnectFn=GWEN_ConnectableMsgEndpoint_SetConnectFn(ep, _connect); GWEN_ConnectableMsgEndpoint_SetFullyConnectedState(ep, GWEN_ENDPOINT_MQTTC_STATE_ESTABLISHED); @@ -190,34 +188,6 @@ void AQH_MqttClientEndpoint_SetTopicPrefix(GWEN_MSG_ENDPOINT *ep, const char *s) -void _run(GWEN_MSG_ENDPOINT *ep) -{ - AQH_ENDPOINT_MQTTC *xep; - - xep=GWEN_INHERIT_GETDATA(GWEN_MSG_ENDPOINT, AQH_ENDPOINT_MQTTC, ep); - if (xep) { - int state; - - if (xep->previousRunFn) - xep->previousRunFn(ep); - - state=GWEN_ConnectableMsgEndpoint_GetState(ep); - if (state==GWEN_MSG_ENDPOINT_CONN_STATE_CONNECTED) - _sendConnectMsg(ep); - else if (state==GWEN_ENDPOINT_MQTTC_STATE_WAITFORCONNACK) - _checkForConnAckMsg(ep); - else if (state==GWEN_ENDPOINT_MQTTC_STATE_ESTABLISHED || - state