[Libreoffice-commits] .: writerfilter/source
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Fri Dec 28 12:42:50 PST 2012
writerfilter/source/doctok/WW8ResourceModelImpl.cxx | 6 +++---
writerfilter/source/ooxml/OOXMLParserState.cxx | 2 +-
writerfilter/source/resourcemodel/resourcemodel.cxx | 6 +++---
3 files changed, 7 insertions(+), 7 deletions(-)
New commits:
commit b2b400770586d545c3066672557a84f1e2f01b55
Author: Julien Nabet <serval2412 at yahoo.fr>
Date: Fri Dec 28 21:41:11 2012 +0100
Replace %d by %u in some format strings
Change-Id: Ica066dcdff68c50c10378752be9c3497104b2a0b
diff --git a/writerfilter/source/doctok/WW8ResourceModelImpl.cxx b/writerfilter/source/doctok/WW8ResourceModelImpl.cxx
index 70016d5..4583260 100644
--- a/writerfilter/source/doctok/WW8ResourceModelImpl.cxx
+++ b/writerfilter/source/doctok/WW8ResourceModelImpl.cxx
@@ -58,10 +58,10 @@ void WW8TableDataHandler::startTable(unsigned int nRows, unsigned int nDepth,
char sBuffer[256];
string tmpStr = "<tabledata.table rows=\"";
- snprintf(sBuffer, sizeof(sBuffer), "%d", nRows);
+ snprintf(sBuffer, sizeof(sBuffer), "%u", nRows);
tmpStr += sBuffer;
tmpStr += "\" depth=\"";
- snprintf(sBuffer, sizeof(sBuffer), "%d", nDepth);
+ snprintf(sBuffer, sizeof(sBuffer), "%u", nDepth);
tmpStr += sBuffer;
tmpStr += "\">";
@@ -78,7 +78,7 @@ void WW8TableDataHandler::startRow
{
char sBuffer[256];
- snprintf(sBuffer, sizeof(sBuffer), "%d", nCols);
+ snprintf(sBuffer, sizeof(sBuffer), "%u", nCols);
string tmpStr = "<tabledata.row cells=\"";
tmpStr += sBuffer;
tmpStr += "\">";
diff --git a/writerfilter/source/ooxml/OOXMLParserState.cxx b/writerfilter/source/ooxml/OOXMLParserState.cxx
index 45f8b1c..c2dc79c 100644
--- a/writerfilter/source/ooxml/OOXMLParserState.cxx
+++ b/writerfilter/source/ooxml/OOXMLParserState.cxx
@@ -103,7 +103,7 @@ const string OOXMLParserState::getHandle() const
{
char sBuffer[256];
- snprintf(sBuffer, sizeof(sBuffer), "%d", mnHandle);
+ snprintf(sBuffer, sizeof(sBuffer), "%u", mnHandle);
return sBuffer;
}
diff --git a/writerfilter/source/resourcemodel/resourcemodel.cxx b/writerfilter/source/resourcemodel/resourcemodel.cxx
index 4427774..bf414ca 100644
--- a/writerfilter/source/resourcemodel/resourcemodel.cxx
+++ b/writerfilter/source/resourcemodel/resourcemodel.cxx
@@ -110,10 +110,10 @@ void WW8TableDataHandler::startTable(unsigned int nRows, unsigned int nDepth,
char sBuffer[256];
string tmpStr = "<tabledata.table rows=\"";
- snprintf(sBuffer, sizeof(sBuffer), "%d", nRows);
+ snprintf(sBuffer, sizeof(sBuffer), "%u", nRows);
tmpStr += sBuffer;
tmpStr += "\" depth=\"";
- snprintf(sBuffer, sizeof(sBuffer), "%d", nDepth);
+ snprintf(sBuffer, sizeof(sBuffer), "%u", nDepth);
tmpStr += sBuffer;
tmpStr += "\">";
@@ -130,7 +130,7 @@ void WW8TableDataHandler::startRow
{
char sBuffer[256];
- snprintf(sBuffer, sizeof(sBuffer), "%d", nCols);
+ snprintf(sBuffer, sizeof(sBuffer), "%u", nCols);
string tmpStr = "<tabledata.row cells=\"";
tmpStr += sBuffer;
tmpStr += "\">";
More information about the Libreoffice-commits
mailing list