[Libreoffice-commits] libmspub.git: src/lib
David Tardon
dtardon at redhat.com
Fri May 10 23:36:42 PDT 2013
src/lib/MSPUBParser.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit 20d7c69f9efb6fdee1b08e84e07f78981b78df1a
Author: David Tardon <dtardon at redhat.com>
Date: Sat May 11 08:36:02 2013 +0200
avoid vector index underflow
diff --git a/src/lib/MSPUBParser.cpp b/src/lib/MSPUBParser.cpp
index 7449040..4d1e2ca 100644
--- a/src/lib/MSPUBParser.cpp
+++ b/src/lib/MSPUBParser.cpp
@@ -1537,7 +1537,7 @@ void libmspub::MSPUBParser::parseEscherShape(WPXInputStream *input, const Escher
if (pxId)
{
MSPUB_DEBUG_MSG(("Current Escher shape has pxId %d\n", *pxId));
- if (*pxId <= m_escherDelayIndices.size() && m_escherDelayIndices[*pxId - 1] >= 0)
+ if (*pxId > 0 && *pxId <= m_escherDelayIndices.size() && m_escherDelayIndices[*pxId - 1] >= 0)
{
m_collector->setShapeImgIndex(*shapeSeqNum, m_escherDelayIndices[*pxId - 1]);
}
More information about the Libreoffice-commits
mailing list