summaryrefslogtreecommitdiffstats
path: root/svl/source/passwordcontainer/passwordcontainer.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'svl/source/passwordcontainer/passwordcontainer.cxx')
-rw-r--r--svl/source/passwordcontainer/passwordcontainer.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/svl/source/passwordcontainer/passwordcontainer.cxx b/svl/source/passwordcontainer/passwordcontainer.cxx
index 333e2921b4..90b27c29f7 100644
--- a/svl/source/passwordcontainer/passwordcontainer.cxx
+++ b/svl/source/passwordcontainer/passwordcontainer.cxx
@@ -654,7 +654,10 @@ OUString PasswordContainer::createIV()
{
rtlRandomPool randomPool = mRandomPool.get();
unsigned char iv[RTL_DIGEST_LENGTH_MD5];
- rtl_random_getBytes(randomPool, iv, RTL_DIGEST_LENGTH_MD5);
+ if (rtl_random_getBytes(randomPool, iv, RTL_DIGEST_LENGTH_MD5) != rtl_Random_E_None)
+ {
+ throw uno::RuntimeException("rtl_random_getBytes failed");
+ }
OUStringBuffer aBuffer;
for (sal_uInt8 i : iv)
{