[Libreoffice-commits] core.git: tools/source
Caolán McNamara
caolanm at redhat.com
Tue Nov 25 13:12:58 PST 2014
tools/source/inet/inetmsg.cxx | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
New commits:
commit b1c7f076cfb944c320892ac58600fd96c252f53e
Author: Caolán McNamara <caolanm at redhat.com>
Date: Tue Nov 25 21:12:00 2014 +0000
assert on loading timestamp in kde80951-1.html
Change-Id: I32a9d6cc625537ab6e0940d93bf9a7544df370c8
diff --git a/tools/source/inet/inetmsg.cxx b/tools/source/inet/inetmsg.cxx
index 3a52712..cc3989a 100644
--- a/tools/source/inet/inetmsg.cxx
+++ b/tools/source/inet/inetmsg.cxx
@@ -327,8 +327,8 @@ bool INetRFC822Message::ParseDateField (
rDateTime.SetSec (ParseNumber (aDateField, nIndex)); nIndex++;
rDateTime.SetNanoSec (0);
- if ((aDateField[nIndex] == '+') ||
- (aDateField[nIndex] == '-') )
+ const char cPossiblePlusMinus = nIndex < aDateField.getLength() ? aDateField[nIndex] : 0;
+ if (cPossiblePlusMinus == '+' || cPossiblePlusMinus == '-')
{
// Offset from GMT: "(+|-)HHMM".
bool bEast = (aDateField[nIndex++] == '+');
More information about the Libreoffice-commits
mailing list