diff options
Diffstat (limited to 'sc/source/filter/excel/xeroot.cxx')
-rw-r--r-- | sc/source/filter/excel/xeroot.cxx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sc/source/filter/excel/xeroot.cxx b/sc/source/filter/excel/xeroot.cxx index ce281890f8..c1959767d9 100644 --- a/sc/source/filter/excel/xeroot.cxx +++ b/sc/source/filter/excel/xeroot.cxx @@ -317,8 +317,10 @@ uno::Sequence< beans::NamedValue > XclExpRoot::GenerateEncryptionData( std::u16s { rtlRandomPool aRandomPool = rtl_random_createPool (); sal_uInt8 pnDocId[16]; - rtl_random_getBytes( aRandomPool, pnDocId, 16 ); - + if (rtl_random_getBytes(aRandomPool, pnDocId, 16) != rtl_Random_E_None) + { + throw uno::RuntimeException("rtl_random_getBytes failed"); + } rtl_random_destroyPool( aRandomPool ); sal_uInt16 pnPasswd[16] = {}; |