[libreoffice/f16] Resolves: fdo#45255 edge-case .doc comment import
Caolán McNamara
caolanm at fedoraproject.org
Tue Feb 7 11:48:18 UTC 2012
commit c20b798f711e6249f3850dd71a160c8d88604daa
Author: Caolán McNamara <caolanm at redhat.com>
Date: Mon Jan 30 20:18:10 2012 +0000
Resolves: fdo#45255 edge-case .doc comment import
...-the-request-for-command-line-help-to-oos.patch | 37 +++++++++++++
...ning-stream-size-after-seeking-not-before.patch | 58 ++++++++++++++++++++
libreoffice.spec | 7 ++-
3 files changed, 101 insertions(+), 1 deletions(-)
---
diff --git a/0001-Do-not-pass-the-request-for-command-line-help-to-oos.patch b/0001-Do-not-pass-the-request-for-command-line-help-to-oos.patch
new file mode 100644
index 0000000..d9bc7d5
--- /dev/null
+++ b/0001-Do-not-pass-the-request-for-command-line-help-to-oos.patch
@@ -0,0 +1,37 @@
+commit 0712e5233c1e6c452f5c888351870047673f0da6
+Author: Michal Svec <msvec at novell.com>
+Date: Tue Jul 12 14:16:42 2011 +0200
+
+ Do not pass the request for command line help to oosplash
+
+ - both of these work now: 'libreoffice -h' and 'libreoffice --help'
+ - added two more options: 'libreoffice -V' and 'libreoffice --version'
+ - all of these options work even if there are instances running
+ - there's no 1s delay between startup and actual output
+
+diff --git a/desktop/scripts/soffice.sh b/desktop/scripts/soffice.sh
+index a97f68d..b23d452 100755
+--- a/desktop/scripts/soffice.sh
++++ b/desktop/scripts/soffice.sh
+@@ -97,5 +97,21 @@ AIX)
+ ;;
+ esac
+
++# do not pass the request for command line help to oosplash
++if test "$#" -eq 1; then
++ case "$1" in
++ -h | --h | --he | --hel | --help)
++ "$sd_prog/soffice.bin" --help
++ exit 0
++ ;;
++ -V | --v | --ve | --ver | --vers | --versi | --versio | --version)
++ "$sd_prog/soffice.bin" --version
++ exit 0
++ ;;
++ *)
++ ;;
++ esac
++fi
++
+ # oosplash does the rest: forcing pages in, javaldx etc. are
+ exec $VALGRINDCHECK "$sd_prog/oosplash.bin" "$@"
diff --git a/0001-query-remaining-stream-size-after-seeking-not-before.patch b/0001-query-remaining-stream-size-after-seeking-not-before.patch
new file mode 100644
index 0000000..a669881
--- /dev/null
+++ b/0001-query-remaining-stream-size-after-seeking-not-before.patch
@@ -0,0 +1,58 @@
+From b5a73d4b2b283d3d1a57ac0f66b608998960a873 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Lubo=C5=A1=20Lu=C5=88=C3=A1k?= <l.lunak at suse.cz>
+Date: Mon, 30 Jan 2012 19:07:43 +0100
+Subject: [PATCH] query remaining stream size after seeking, not before
+ (fdo#45255)
+
+---
+ sw/source/filter/ww8/ww8scan.cxx | 18 +++++++++---------
+ 1 files changed, 9 insertions(+), 9 deletions(-)
+
+diff --git a/sw/source/filter/ww8/ww8scan.cxx b/sw/source/filter/ww8/ww8scan.cxx
+index a97f383..593624b 100644
+--- a/sw/source/filter/ww8/ww8scan.cxx
++++ b/sw/source/filter/ww8/ww8scan.cxx
+@@ -1978,10 +1978,11 @@ WW8PLCFspecial::WW8PLCFspecial(SvStream* pSt, sal_uInt32 nFilePos,
+ const sal_uInt32 nValidMin=4;
+
+ sal_Size nOldPos = pSt->Tell();
+- sal_Size nRemainingSize = pSt->remainingSize();
+
+- bool bValid = checkSeek(*pSt, nFilePos) && (nRemainingSize >= nValidMin) &&
+- (nPLCF >= nValidMin);
++ bool bValid = checkSeek(*pSt, nFilePos);
++ sal_Size nRemainingSize = pSt->remainingSize();
++ if( !(nRemainingSize >= nValidMin && nPLCF >= nValidMin ))
++ bValid = false;
+ nPLCF = bValid ? std::min(nRemainingSize, static_cast<sal_Size>(nPLCF)) : nValidMin;
+
+ // Pointer auf Pos- u. Struct-Array
+@@ -2136,9 +2137,7 @@ WW8PLCF::WW8PLCF(SvStream& rSt, WW8_FC nFilePos, sal_Int32 nPLCF, int nStruct,
+ void WW8PLCF::ReadPLCF(SvStream& rSt, WW8_FC nFilePos, sal_uInt32 nPLCF)
+ {
+ sal_Size nOldPos = rSt.Tell();
+- sal_Size nRemainingSize = rSt.remainingSize();
+-
+- bool bValid = checkSeek(rSt, nFilePos) && (nRemainingSize >= nPLCF);
++ bool bValid = checkSeek(rSt, nFilePos) && (rSt.remainingSize() >= nPLCF);
+
+ if (bValid)
+ {
+@@ -2317,10 +2316,11 @@ WW8PLCFpcd::WW8PLCFpcd(SvStream* pSt, sal_uInt32 nFilePos,
+ const sal_uInt32 nValidMin=4;
+
+ sal_Size nOldPos = pSt->Tell();
+- sal_Size nRemainingSize = pSt->remainingSize();
+
+- bool bValid = checkSeek(*pSt, nFilePos) && (nRemainingSize >= nValidMin) &&
+- (nPLCF >= nValidMin);
++ bool bValid = checkSeek(*pSt, nFilePos);
++ sal_Size nRemainingSize = pSt->remainingSize();
++ if( !(nRemainingSize >= nValidMin && nPLCF >= nValidMin ))
++ bValid = false;
+ nPLCF = bValid ? std::min(nRemainingSize, static_cast<sal_Size>(nPLCF)) : nValidMin;
+
+ pPLCF_PosArray = new sal_Int32[ ( nPLCF + 3 ) / 4 ]; // Pointer auf Pos-Array
+--
+1.7.6.5
+
diff --git a/libreoffice.spec b/libreoffice.spec
index 9df1fab..449089c 100644
--- a/libreoffice.spec
+++ b/libreoffice.spec
@@ -186,6 +186,8 @@ Patch67: 0003-fdo-38542-sw-ODF-import-divide-width-by-3-for-double.patch
Patch68: 0004-fdo-38542-sw-ODF-import-prevent-border-width-overrid.patch
Patch69: 0001-rhbz-746174-also-export-list-restart-for-non-root-li.patch
Patch70: 0001-resolved-fdo-42784-BorderLine-with-only-InnerWidth-s.patch
+Patch71: 0001-query-remaining-stream-size-after-seeking-not-before.patch
+Patch72: 0001-Do-not-pass-the-request-for-command-line-help-to-oos.patch
%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
%define instdir %{_libdir}
@@ -1044,6 +1046,8 @@ mv -f redhat.soc extras/source/palettes/standard.soc
%patch68 -p1 -b .fdo-38542-sw-ODF-import-prevent-border-width-overrid.patch
%patch69 -p1 -b .rhbz-746174-also-export-list-restart-for-non-root-li.patch
%patch70 -p1 -b .resolved-fdo-42784-BorderLine-with-only-InnerWidth-s.patch
+%patch71 -p1 -b .query-remaining-stream-size-after-seeking-not-before.patch
+%patch72 -p1 -b .Do-not-pass-the-request-for-command-line-help-to-oos.patch
# these are horribly incomplete--empty translations and copied english
# strings with spattering of translated strings
@@ -2354,7 +2358,7 @@ update-desktop-database %{_datadir}/applications &> /dev/null || :
%endif
%changelog
-* Tue Jan 17 2012 David Tardon <dtardon at redhat.com> - 3.4.5.2-2-UNBUILT
+* Tue Feb 07 2012 Caolán McNamara <caolanm at redhat.com> - 3.4.5.2-2
- Resolves: fdo#44040 VIEWING: Crash when page preview after <f4>
- Resolves: fdo#39118 Fixed chart listener registration during ODS import
- Resolves: fdo#43725 crash on saving a file
@@ -2374,6 +2378,7 @@ update-desktop-database %{_datadir}/applications &> /dev/null || :
avoid crashes and loops
- Resolves: rhbz#746174 also export list restart for non root list
- Resolves: fdo#42784 BorderLine with only InnerWidth set does not work
+- Resolves: fdo#45255 edge-case .doc comment import
* Tue Jan 17 2012 David Tardon <dtardon at redhat.com> - 3.4.5.2-1
- new upstream version 3.4.5
More information about the scm-commits
mailing list