cid#1607989 Overflowed constant

and

cid#1607976 Overflowed constant
cid#1607855 Overflowed constant
cid#1607731 Overflowed constant

Change-Id: I18e8ffb8a9b5a55e0ecb71862549a94ff5c2fc1a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/173781
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
This commit is contained in:
Caolán McNamara
2024-09-23 09:32:54 +02:00
parent dcde476695
commit 08964038e1
4 changed files with 11 additions and 4 deletions
+2 -1
View File
@@ -1204,7 +1204,8 @@ OString NetProducer::getNetName(std::string_view name)
// if polymorphic, process parameters too
if (fullNameView.ends_with('>'))
{
size_t start = fullNameView.find_first_of('<') + 1;
const std::string_view::size_type nFirstAngle = fullNameView.find_first_of('<');
size_t start = (nFirstAngle != std::string_view::npos) ? (nFirstAngle + 1) : 0;
size_t end = fullNameView.size() - 1;
buffer.append(fullNameView.substr(0, start));
OString params(fullNameView.substr(start, end - start));