summaryrefslogtreecommitdiff
path: root/sal
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2022-09-07 17:08:38 +0100
committerCaolán McNamara <caolanm@redhat.com>2022-09-13 09:56:12 +0200
commitf0f0d385b91df30d4ec42a9f727cbdbe5ce0861f (patch)
tree93588d5e1e83c019e9e06a0d9412f327fa3e9beb /sal
parent2a5eed7d10c378f29e4de74934aff4c78fccbda6 (diff)
cid#1509232 silence Out-of-bounds access
Change-Id: I53f0e0ead728c718d1241d1791135c3c60311303 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139608 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Jenkins
Diffstat (limited to 'sal')
-rw-r--r--sal/osl/unx/security.cxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/sal/osl/unx/security.cxx b/sal/osl/unx/security.cxx
index 1b1f16a54edc..b15ec9e773b0 100644
--- a/sal/osl/unx/security.cxx
+++ b/sal/osl/unx/security.cxx
@@ -106,6 +106,8 @@ static oslSecurityImpl * growSecurityImpl(
}
p = static_cast<oslSecurityImpl *>(realloc(impl, n));
if (p != nullptr) {
+ // coverity[overrun-buffer-arg] - theoretically massive n is not due to
+ // a negative parameter being interpreted as unsigned
memset (p, 0, n);
}
}