[Libreoffice-commits] core.git: oox/source

Markus Mohrhard markus.mohrhard at collabora.co.uk
Mon Feb 10 15:19:48 PST 2014


 oox/source/crypto/CryptTools.cxx |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

New commits:
commit db96add4686875efce6a6e6bc6a860b249b0c210
Author: Markus Mohrhard <markus.mohrhard at collabora.co.uk>
Date:   Tue Feb 11 00:08:24 2014 +0100

    fix crash during file format detection, related #i101863#
    
    Change-Id: I2aec2e95f49ab70a9e94c5d52f70855f4381a24e

diff --git a/oox/source/crypto/CryptTools.cxx b/oox/source/crypto/CryptTools.cxx
index 6c46297..d9ba500 100644
--- a/oox/source/crypto/CryptTools.cxx
+++ b/oox/source/crypto/CryptTools.cxx
@@ -61,7 +61,10 @@ void Crypto::setupContext(vector<sal_uInt8>& key, vector<sal_uInt8>& iv, CryptoT
 
     SECItem ivItem;
     ivItem.type = siBuffer;
-    ivItem.data = &iv[0];
+    if(iv.empty())
+        ivItem.data = NULL;
+    else
+        ivItem.data = &iv[0];
     ivItem.len = iv.size();
 
     SECItem* pIvItem = NULL;


More information about the Libreoffice-commits mailing list