diff --git a/src/expat/lib/xmlparse.c b/src/expat/lib/xmlparse.c index 322c8eeee6..dbf5687613 100644 --- a/src/expat/lib/xmlparse.c +++ b/src/expat/lib/xmlparse.c @@ -1703,13 +1703,16 @@ XML_GetBuffer(XML_Parser parser, int len) } if (len > bufferLim - bufferEnd) { +#ifdef XML_CONTEXT_BYTES + int keep; +#endif int neededSize = len + (int)(bufferEnd - bufferPtr); if (neededSize < 0) { errorCode = XML_ERROR_NO_MEMORY; return NULL; } #ifdef XML_CONTEXT_BYTES - int keep = (int)(bufferPtr - buffer); + keep = (int)(bufferPtr - buffer); if (keep > XML_CONTEXT_BYTES) keep = XML_CONTEXT_BYTES;