diff options
author | Caolán McNamara <caolanm@redhat.com> | 2018-02-09 11:30:10 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2018-02-09 22:03:00 +0100 |
commit | 05e3feb495ff3078c80b1af6aad7c33ac5340b01 (patch) | |
tree | 28285fcb1414f973f2a99868a1766f0d76bf7f61 /xmloff | |
parent | 017fcc2fcd00af17a97bd5463d89662404f57667 (diff) |
ofz#6180 Integer-overflow
Change-Id: I6339a6ebb188dc9e7bccfa629a40af8e67c13feb
Reviewed-on: https://gerrit.libreoffice.org/49487
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'xmloff')
-rw-r--r-- | xmloff/source/core/unointerfacetouniqueidentifiermapper.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/xmloff/source/core/unointerfacetouniqueidentifiermapper.cxx b/xmloff/source/core/unointerfacetouniqueidentifiermapper.cxx index 795aa5838218..5e144d7f7053 100644 --- a/xmloff/source/core/unointerfacetouniqueidentifiermapper.cxx +++ b/xmloff/source/core/unointerfacetouniqueidentifiermapper.cxx @@ -166,7 +166,7 @@ void UnoInterfaceToUniqueIdentifierMapper::insertReference( const OUString& rIde // so we make sure we will never generate // an integer value like this one sal_Int32 nId = rIdentifier.copy(2).toInt32(); - if( mnNextId <= nId ) + if (nId > 0 && mnNextId <= static_cast<sal_uInt32>(nId)) mnNextId = nId + 1; } |