diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2019-04-01 00:25:16 +0300 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2019-04-01 00:49:12 +0200 |
commit | 85456fae54029edd26df2277a9eec5e2fe3d9739 (patch) | |
tree | fd55ad48b34c66f0b839edcbc952a8a5a0752c72 /sal | |
parent | 1d35b89e7581e12024769d19bfb6d6eb2c3274b8 (diff) |
tdf#120703 PVS: Silence V522 warnings
V522 There might be dereferencing of a potential null pointer.
Change-Id: Ie617b41a8f8d334022cf5313b242a236baedba48
Reviewed-on: https://gerrit.libreoffice.org/70017
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'sal')
-rw-r--r-- | sal/osl/w32/backtrace.cxx | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sal/osl/w32/backtrace.cxx b/sal/osl/w32/backtrace.cxx index 160d4e7d0207..9e31616eaaff 100644 --- a/sal/osl/w32/backtrace.cxx +++ b/sal/osl/w32/backtrace.cxx @@ -55,6 +55,7 @@ OUString osl::detail::backtraceAsString(sal_uInt32 maxDepth) SYMBOL_INFO * pSymbol; pSymbol = static_cast<SYMBOL_INFO *>(calloc( sizeof( SYMBOL_INFO ) + 1024 * sizeof( char ), 1 )); + assert(pSymbol); pSymbol->MaxNameLen = 1024 - 1; pSymbol->SizeOfStruct = sizeof( SYMBOL_INFO ); @@ -99,6 +100,7 @@ OUString sal::backtrace_to_string(BacktraceState* backtraceState) SYMBOL_INFO * pSymbol; pSymbol = static_cast<SYMBOL_INFO *>(calloc( sizeof( SYMBOL_INFO ) + 1024 * sizeof( char ), 1 )); + assert(pSymbol); pSymbol->MaxNameLen = 1024 - 1; pSymbol->SizeOfStruct = sizeof( SYMBOL_INFO ); HANDLE hProcess = GetCurrentProcess(); |