[Libreoffice-commits] .: libvisio/libvisio-0.0.17-fdo48601_part2.patch libvisio/makefile.mk

Fridrich Strba fridrich at kemper.freedesktop.org
Mon Jun 18 01:20:52 PDT 2012


 libvisio/libvisio-0.0.17-fdo48601_part2.patch |   64 ++++++++++++++++++++++++++
 libvisio/makefile.mk                          |    1 
 2 files changed, 65 insertions(+)

New commits:
commit 1d1c70d8114a28a0d37315d408fdc3ef25cf44df
Author: Fridrich Å trba <fridrich.strba at bluewin.ch>
Date:   Mon Jun 18 10:20:27 2012 +0200

    Trying to solve out of bonds in fdo#48601
    
    Change-Id: Idf9d56714d658a14af826a74c58aad26a9e29414

diff --git a/libvisio/libvisio-0.0.17-fdo48601_part2.patch b/libvisio/libvisio-0.0.17-fdo48601_part2.patch
new file mode 100644
index 0000000..5b65d8d
--- /dev/null
+++ b/libvisio/libvisio-0.0.17-fdo48601_part2.patch
@@ -0,0 +1,64 @@
+--- misc/libvisio-0.0.17/src/lib/VSDXContentCollector.cpp	2012-06-18 10:18:48.450129329 +0200
++++ misc/build/libvisio-0.0.17/src/lib/VSDXContentCollector.cpp	2012-06-18 10:18:17.935927778 +0200
+@@ -91,7 +91,8 @@
+   else if (m_fillPattern == 1)
+   {
+     m_fillType = "solid";
+-    m_styleProps.insert("draw:fill-color", getColourString(m_colours[colourIndexFG]));
++    if (colourIndexFG < m_colours.size())
++      m_styleProps.insert("draw:fill-color", getColourString(m_colours[colourIndexFG]));
+     if (m_fillFGTransparency > 0)
+       m_styleProps.insert("draw:opacity", (double)(1 - m_fillFGTransparency/255.0), WPX_PERCENT);
+     else
+@@ -101,8 +102,10 @@
+   {
+     m_fillType = "gradient";
+     m_styleProps.insert("draw:style", "axial");
+-    m_styleProps.insert("draw:start-color", getColourString(m_colours[colourIndexFG]));
+-    m_styleProps.insert("draw:end-color", getColourString(m_colours[colourIndexBG]));
++    if (colourIndexFG < m_colours.size())
++      m_styleProps.insert("draw:start-color", getColourString(m_colours[colourIndexFG]));
++    if (colourIndexBG < m_colours.size())
++      m_styleProps.insert("draw:end-color", getColourString(m_colours[colourIndexBG]));
+     m_styleProps.remove("draw:opacity");
+     if (m_fillBGTransparency > 0)
+       m_styleProps.insert("libwpg:start-opacity", (double)(1 - m_fillBGTransparency/255.0), WPX_PERCENT);
+@@ -123,8 +126,10 @@
+   {
+     m_fillType = "gradient";
+     m_styleProps.insert("draw:style", "linear");
+-    m_styleProps.insert("draw:start-color", getColourString(m_colours[colourIndexBG]));
+-    m_styleProps.insert("draw:end-color", getColourString(m_colours[colourIndexFG]));
++    if (colourIndexBG < m_colours.size())
++      m_styleProps.insert("draw:start-color", getColourString(m_colours[colourIndexBG]));
++    if (colourIndexFG < m_colours.size())
++      m_styleProps.insert("draw:end-color", getColourString(m_colours[colourIndexFG]));
+     m_styleProps.remove("draw:opacity");
+     if (m_fillBGTransparency > 0)
+       m_styleProps.insert("libwpg:start-opacity", (double)(1 - m_fillBGTransparency/255.0), WPX_PERCENT);
+@@ -170,8 +175,10 @@
+     m_styleProps.insert("draw:style", "rectangular");
+     m_styleProps.insert("svg:cx", 0.5, WPX_PERCENT);
+     m_styleProps.insert("svg:cy", 0.5, WPX_PERCENT);
+-    m_styleProps.insert("draw:start-color", getColourString(m_colours[colourIndexBG]));
+-    m_styleProps.insert("draw:end-color", getColourString(m_colours[colourIndexFG]));
++    if (colourIndexBG < m_colours.size())
++      m_styleProps.insert("draw:start-color", getColourString(m_colours[colourIndexBG]));
++    if (colourIndexFG < m_colours.size())
++      m_styleProps.insert("draw:end-color", getColourString(m_colours[colourIndexFG]));
+     m_styleProps.remove("draw:opacity");
+     if (m_fillBGTransparency > 0)
+       m_styleProps.insert("libwpg:start-opacity", (double)(1 - m_fillBGTransparency/255.0), WPX_PERCENT);
+@@ -188,8 +195,10 @@
+   {
+     m_fillType = "gradient";
+     m_styleProps.insert("draw:style", "radial");
+-    m_styleProps.insert("draw:start-color", getColourString(m_colours[colourIndexBG]));
+-    m_styleProps.insert("draw:end-color", getColourString(m_colours[colourIndexFG]));
++    if (colourIndexBG < m_colours.size())
++      m_styleProps.insert("draw:start-color", getColourString(m_colours[colourIndexBG]));
++    if (colourIndexFG < m_colours.size())
++      m_styleProps.insert("draw:end-color", getColourString(m_colours[colourIndexFG]));
+     m_styleProps.remove("draw:opacity");
+     if (m_fillBGTransparency > 0)
+       m_styleProps.insert("libwpg:start-opacity", (double)(1 - m_fillBGTransparency/255.0), WPX_PERCENT);
diff --git a/libvisio/makefile.mk b/libvisio/makefile.mk
index 2855741..1de538b 100644
--- a/libvisio/makefile.mk
+++ b/libvisio/makefile.mk
@@ -60,6 +60,7 @@ TARFILE_MD5=90010e213dd25648e70f0cc12f8fed55
 PATCH_FILES=\
 	$(TARFILE_NAME)-fdo50988.patch \
 	$(TARFILE_NAME)-fdo48601_part1.patch \
+	$(TARFILE_NAME)-fdo48601_part2.patch \
 	$(TARFILE_NAME).patch
 
 BUILD_ACTION=dmake $(MFLAGS) $(CALLMACROS)


More information about the Libreoffice-commits mailing list