[ooo-build-commit] Branch 'ooo-build-3-1' - patches/dev300
Kohei Yoshida
kohei at kemper.freedesktop.org
Thu Jun 18 08:05:17 PDT 2009
patches/dev300/apply | 5 +++-
patches/dev300/calc-xls-decryption-crash-fix.diff | 24 ++++++++++++++++++++++
2 files changed, 28 insertions(+), 1 deletion(-)
New commits:
commit bcb0634093264471e4d72dde652b2790059a3a61
Author: Kohei Yoshida <kyoshida at novell.com>
Date: Thu Jun 18 11:07:07 2009 -0400
Fixed a crasher upon loading xls doc with unsupported encryption.
See i#102906 for details.
* patches/dev300/apply:
* patches/dev300/calc-xls-decryption-crash-fix.diff:
diff --git a/patches/dev300/apply b/patches/dev300/apply
index 711dba4..6d49330 100644
--- a/patches/dev300/apply
+++ b/patches/dev300/apply
@@ -730,8 +730,11 @@ vba-sc-autoshapes-hyperlinks.diff, i#66550, noelpwer
# protected. Also to support encryption on Excel file export.
cws-scsheetprotection02-sfx2.diff, i#97515, kohei
cws-scsheetprotection02-svx.diff, i#97515, kohei
-
cws-scsheetprotection02-sc.diff, i#97515, kohei
+
+# fix a crasher when loading xls doc with unsupported encryption.
+calc-xls-decryption-crash-fix.diff, i#102906, kohei
+
# Unit conversion fixes in ScDrawLayer.
sc-drwlayer-units.diff, i#83735, jonp
# overwrite character level font attributes when changing them at cell level.
diff --git a/patches/dev300/calc-xls-decryption-crash-fix.diff b/patches/dev300/calc-xls-decryption-crash-fix.diff
new file mode 100644
index 0000000..934e000
--- /dev/null
+++ b/patches/dev300/calc-xls-decryption-crash-fix.diff
@@ -0,0 +1,24 @@
+Index: sc/source/filter/excel/xicontent.cxx
+===================================================================
+--- sc/source/filter/excel/xicontent.cxx (revision 270727)
++++ sc/source/filter/excel/xicontent.cxx (working copy)
+@@ -1096,6 +1096,10 @@
+ case EXC_BIFF8: xDecr = lclReadFilepass8( rStrm ); break;
+ default: DBG_ERROR_BIFF();
+ };
++
++ if (!xDecr.is())
++ return EXC_ENCR_ERROR_UNSUPP_CRYPT;
++
+ // set decrypter at import stream
+ rStrm.SetDecrypter( xDecr );
+
+@@ -1107,7 +1111,7 @@
+ pSet->Put( SfxStringItem(SID_PASSWORD, aPass) );
+ }
+
+- return xDecr.is() ? xDecr->GetError() : EXC_ENCR_ERROR_UNSUPP_CRYPT;
++ return xDecr->GetError();
+ }
+
+ // Document protection ========================================================
More information about the ooo-build-commit
mailing list