[Libreoffice-commits] libcdr.git: src/lib

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Fri Mar 26 17:59:56 UTC 2021


 src/lib/CDRParser.cpp |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

New commits:
commit 55bfa48a55dfa090cb4fa4fdcd9eae309a5a1252
Author:     Fridrich Štrba <fridrich.strba at bluewin.ch>
AuthorDate: Fri Mar 26 18:59:28 2021 +0100
Commit:     Fridrich Štrba <fridrich.strba at bluewin.ch>
CommitDate: Fri Mar 26 18:59:28 2021 +0100

    Unused value + some more meaningful debug output
    
    Change-Id: Ic8e94d97a8e85efd47c5e4f6ed9dcd87dedaa570

diff --git a/src/lib/CDRParser.cpp b/src/lib/CDRParser.cpp
index a309355..b9a95e9 100644
--- a/src/lib/CDRParser.cpp
+++ b/src/lib/CDRParser.cpp
@@ -113,7 +113,6 @@ static int parseColourString(const char *colourString, libcdr::CDRColor &colour,
 
   boost::optional<unsigned> colourModel, colourPalette;
   std::vector<std::string> fallbackColours;
-  std::string rest;
   std::vector<unsigned> val;
 
   if (colourString)
@@ -172,6 +171,8 @@ static int parseColourString(const char *colourString, libcdr::CDRColor &colour,
     CDR_DEBUG_MSG(("parseColourString --> spirit grammar failed with string: %s\n", colourString));
     return -1;
   }
+  CDR_DEBUG_MSG(("parseColourString --> colourModel %u, colourPalette %u, val size %lu, num fallback %lu\n",
+                 colourModel ? colourModel.get() : 0, colourPalette ? colourPalette.get() : 0, val.size(), fallbackColours.size()));
 
   // If fallback colours exist, use the first of them, since we are more likely
   // to get them right then the paletted spot colours
@@ -216,10 +217,10 @@ static int parseColourString(const char *colourString, libcdr::CDRColor &colour,
   }
   else
   {
-    CDR_DEBUG_MSG(("parseColourString --> bRes %i, size %lu, colorModel %u, colorValue 0x%.8x bkp: %lu\n", bRes, val.size(), colour.m_colorModel, colour.m_colorValue, fallbackColours.size()));
+    CDR_DEBUG_MSG(("parseColourString --> colourModel %u, colorValue 0x%.8x, return 0\n", colour.m_colorModel, colour.m_colorValue));
     return 0;
   }
-  CDR_DEBUG_MSG(("parseColourString --> bRes %i, size %lu, colorModel %u, colorValue 0x%.8x blp: %lu\n", bRes, val.size(), colour.m_colorModel, colour.m_colorValue, fallbackColours.size()));
+  CDR_DEBUG_MSG(("parseColourString --> colourModel %u, colorValue 0x%.8x, return 1\n", colour.m_colorModel, colour.m_colorValue));
   return 1;
 }
 


More information about the Libreoffice-commits mailing list