Fixed HTTP API XML response

This commit is contained in:
cschwinne 2019-03-19 12:19:48 +01:00
parent 1a71872c7b
commit a2da0b0641
2 changed files with 3 additions and 8 deletions

View File

@ -99,7 +99,7 @@
//version code in format yymmddb (b = daily build)
#define VERSION 1903161
#define VERSION 1903191
char versionString[] = "0.8.4-dev";

View File

@ -5,13 +5,8 @@
//build XML response to HTTP /win API request
char* XML_response(AsyncWebServerRequest *request, bool includeTheme, char* dest = nullptr)
{
if (dest == nullptr) //allocate local buffer if none passed
{
char sbuf[1024];
obuf = sbuf;
} else {
obuf = dest;
}
char sbuf[(dest == nullptr)?1024:1]; //allocate local buffer if none passed
obuf = (dest == nullptr)? sbuf:dest;
olen = 0;
oappend("<?xml version=\"1.0\" ?><vs><ac>");