Kaydet (Commit) 05e3feb4 authored tarafından Caolán McNamara's avatar Caolán McNamara

ofz#6180 Integer-overflow

Change-Id: I6339a6ebb188dc9e7bccfa629a40af8e67c13feb
Reviewed-on: https://gerrit.libreoffice.org/49487Reviewed-by: 's avatarCaolán McNamara <caolanm@redhat.com>
Tested-by: 's avatarCaolán McNamara <caolanm@redhat.com>
üst 017fcc2f
......@@ -75,7 +75,7 @@ private:
void insertReference( const OUString& rIdentifier, const css::uno::Reference< css::uno::XInterface >& rInterface );
IdMap_t maEntries;
sal_Int32 mnNextId;
sal_uInt32 mnNextId;
};
}
......
......@@ -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;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment