aqhome-storage now checks and parses mqtt messages and stores values in datafiles.

This commit is contained in:
Martin Preuss
2023-08-12 16:55:06 +02:00
parent bcd3e3325c
commit a4c0f2e6fd
18 changed files with 517 additions and 53 deletions

View File

@@ -522,7 +522,8 @@ void _abortMessage(GWEN_MSG_ENDPOINT *ep)
DBG_DEBUG(AQH_LOGDOMAIN, "Aborting message (if any).");
xep=GWEN_INHERIT_GETDATA(GWEN_MSG_ENDPOINT, AQH_ENDPOINT_HTTP, ep);
GWEN_Buffer_Reset(xep->currentReadBuffer);
if (xep->currentReadBuffer)
GWEN_Buffer_Reset(xep->currentReadBuffer);
xep->currentHeaderPos=0;
xep->currentBodyPos=0;
xep->currentBodySize=0;

View File

@@ -657,7 +657,9 @@ int _unescapeUrlEncoded(const char *src, unsigned int srclen, char *buffer, unsi
x=='.' ||
x=='*' ||
x=='?' ||
x=='+'
x=='+' ||
x=='-' ||
x=='_'
) {
if (size<(maxsize-1)) {
buffer[size++]=(x=='+')?' ':x;