summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel <noelgrandin@gmail.com>2020-11-17 10:25:45 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2020-11-18 07:23:45 +0100
commit3fc10def9e82cccf3e2bb2aacadafcb321ad0773 (patch)
treedda1819beb5e52fbcdbdd0ce3a84dbd4dada1fac
parent57f9fad565fed476b95cd53f2d025add577affe6 (diff)
fix XMLOFF_WARN_UNKNOWN
since (doh!) having it as a function does not correctly log the actual caller source line information. Change-Id: Iae1007414259dea372f761765e090e1ed2ddbea9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105972 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r--include/xmloff/xmlictxt.hxx3
-rw-r--r--reportdesign/source/filter/xml/xmlCell.cxx1
-rw-r--r--reportdesign/source/filter/xml/xmlColumn.cxx1
-rw-r--r--reportdesign/source/filter/xml/xmlComponent.cxx1
-rw-r--r--reportdesign/source/filter/xml/xmlCondPrtExpr.cxx1
-rw-r--r--reportdesign/source/filter/xml/xmlControlProperty.cxx1
-rw-r--r--reportdesign/source/filter/xml/xmlFormatCondition.cxx1
-rw-r--r--reportdesign/source/filter/xml/xmlFormattedField.cxx1
-rw-r--r--reportdesign/source/filter/xml/xmlFunction.cxx1
-rw-r--r--reportdesign/source/filter/xml/xmlGroup.cxx1
-rw-r--r--reportdesign/source/filter/xml/xmlMasterFields.cxx1
-rw-r--r--reportdesign/source/filter/xml/xmlReportElement.cxx1
-rw-r--r--reportdesign/source/filter/xml/xmlSection.cxx1
-rw-r--r--reportdesign/source/filter/xml/xmlTable.cxx1
-rw-r--r--xmloff/source/core/xmlictxt.cxx5
15 files changed, 15 insertions, 6 deletions
diff --git a/include/xmloff/xmlictxt.hxx b/include/xmloff/xmlictxt.hxx
index 69fa648b64f8..82f4c11632f1 100644
--- a/include/xmloff/xmlictxt.hxx
+++ b/include/xmloff/xmlictxt.hxx
@@ -128,7 +128,8 @@ public:
virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId( ) final override;
};
-void XMLOFF_DLLPUBLIC XMLOFF_WARN_UNKNOWN(const char *area, sax_fastparser::FastAttributeList::FastAttributeIter const & rIter);
+#define XMLOFF_WARN_UNKNOWN(area, rIter) \
+ SAL_WARN(area, "unknown attribute " << SvXMLImport::getPrefixAndNameFromToken(rIter.getToken()) << " value=" << rIter.toString());
#define XMLOFF_WARN_UNKNOWN_ATTR(area, token, value) \
SAL_WARN(area, "unknown attribute " << SvXMLImport::getPrefixAndNameFromToken(token) << "=" << value);
diff --git a/reportdesign/source/filter/xml/xmlCell.cxx b/reportdesign/source/filter/xml/xmlCell.cxx
index 7cca71988885..a118970e106b 100644
--- a/reportdesign/source/filter/xml/xmlCell.cxx
+++ b/reportdesign/source/filter/xml/xmlCell.cxx
@@ -30,6 +30,7 @@
#include <com/sun/star/report/XFixedLine.hpp>
#include <com/sun/star/table/BorderLine2.hpp>
#include <osl/diagnose.h>
+#include <sal/log.hxx>
#include <strings.hxx>
#include "xmlTable.hxx"
#include "xmlFormattedField.hxx"
diff --git a/reportdesign/source/filter/xml/xmlColumn.cxx b/reportdesign/source/filter/xml/xmlColumn.cxx
index da62a8ae6d20..f98f6507ffc5 100644
--- a/reportdesign/source/filter/xml/xmlColumn.cxx
+++ b/reportdesign/source/filter/xml/xmlColumn.cxx
@@ -32,6 +32,7 @@
#include <comphelper/propertysetinfo.hxx>
#include <com/sun/star/beans/PropertyAttribute.hpp>
#include <strings.hxx>
+#include <sal/log.hxx>
#define PROPERTY_ID_WIDTH 1
#define PROPERTY_ID_HEIGHT 2
diff --git a/reportdesign/source/filter/xml/xmlComponent.cxx b/reportdesign/source/filter/xml/xmlComponent.cxx
index dfb773c4896e..c6433d2a87ed 100644
--- a/reportdesign/source/filter/xml/xmlComponent.cxx
+++ b/reportdesign/source/filter/xml/xmlComponent.cxx
@@ -21,6 +21,7 @@
#include <xmloff/xmltoken.hxx>
#include <xmloff/xmlnamespace.hxx>
#include <osl/diagnose.h>
+#include <sal/log.hxx>
namespace rptxml
{
diff --git a/reportdesign/source/filter/xml/xmlCondPrtExpr.cxx b/reportdesign/source/filter/xml/xmlCondPrtExpr.cxx
index 1c1331b206c3..5ffd0284e520 100644
--- a/reportdesign/source/filter/xml/xmlCondPrtExpr.cxx
+++ b/reportdesign/source/filter/xml/xmlCondPrtExpr.cxx
@@ -22,6 +22,7 @@
#include <xmloff/xmlnamespace.hxx>
#include <strings.hxx>
#include <osl/diagnose.h>
+#include <sal/log.hxx>
namespace rptxml
{
diff --git a/reportdesign/source/filter/xml/xmlControlProperty.cxx b/reportdesign/source/filter/xml/xmlControlProperty.cxx
index 0a921f328dc5..fce0ef4cba11 100644
--- a/reportdesign/source/filter/xml/xmlControlProperty.cxx
+++ b/reportdesign/source/filter/xml/xmlControlProperty.cxx
@@ -37,6 +37,7 @@
#include <com/sun/star/util/DateTime.hpp>
#include <rtl/math.hxx>
#include <osl/diagnose.h>
+#include <sal/log.hxx>
#define TYPE_DATE 1
#define TYPE_TIME 2
diff --git a/reportdesign/source/filter/xml/xmlFormatCondition.cxx b/reportdesign/source/filter/xml/xmlFormatCondition.cxx
index eff2ef7b8967..ca381b22760b 100644
--- a/reportdesign/source/filter/xml/xmlFormatCondition.cxx
+++ b/reportdesign/source/filter/xml/xmlFormatCondition.cxx
@@ -22,6 +22,7 @@
#include <xmloff/xmlnamespace.hxx>
#include "xmlHelper.hxx"
#include <osl/diagnose.h>
+#include <sal/log.hxx>
namespace rptxml
{
diff --git a/reportdesign/source/filter/xml/xmlFormattedField.cxx b/reportdesign/source/filter/xml/xmlFormattedField.cxx
index 88551c909f71..4c419844e756 100644
--- a/reportdesign/source/filter/xml/xmlFormattedField.cxx
+++ b/reportdesign/source/filter/xml/xmlFormattedField.cxx
@@ -21,6 +21,7 @@
#include <xmloff/xmltoken.hxx>
#include <xmloff/xmlnamespace.hxx>
#include <osl/diagnose.h>
+#include <sal/log.hxx>
namespace rptxml
diff --git a/reportdesign/source/filter/xml/xmlFunction.cxx b/reportdesign/source/filter/xml/xmlFunction.cxx
index a47a7ba7d6e3..1c26aa4dd27c 100644
--- a/reportdesign/source/filter/xml/xmlFunction.cxx
+++ b/reportdesign/source/filter/xml/xmlFunction.cxx
@@ -21,6 +21,7 @@
#include <xmloff/xmltoken.hxx>
#include <xmloff/xmlnamespace.hxx>
#include <osl/diagnose.h>
+#include <sal/log.hxx>
namespace rptxml
{
diff --git a/reportdesign/source/filter/xml/xmlGroup.cxx b/reportdesign/source/filter/xml/xmlGroup.cxx
index 15ea2ac6f144..be7fc44e4d5d 100644
--- a/reportdesign/source/filter/xml/xmlGroup.cxx
+++ b/reportdesign/source/filter/xml/xmlGroup.cxx
@@ -29,6 +29,7 @@
#include <com/sun/star/report/GroupOn.hpp>
#include <com/sun/star/report/KeepTogether.hpp>
#include <osl/diagnose.h>
+#include <sal/log.hxx>
namespace rptxml
{
diff --git a/reportdesign/source/filter/xml/xmlMasterFields.cxx b/reportdesign/source/filter/xml/xmlMasterFields.cxx
index 2dfd0ac4d9b1..64cb935db286 100644
--- a/reportdesign/source/filter/xml/xmlMasterFields.cxx
+++ b/reportdesign/source/filter/xml/xmlMasterFields.cxx
@@ -23,6 +23,7 @@
#include <xmloff/xmlnamespace.hxx>
#include <xmloff/ProgressBarHelper.hxx>
#include "xmlEnums.hxx"
+#include <sal/log.hxx>
namespace rptxml
diff --git a/reportdesign/source/filter/xml/xmlReportElement.cxx b/reportdesign/source/filter/xml/xmlReportElement.cxx
index 47adb6c21903..14e3958d3c94 100644
--- a/reportdesign/source/filter/xml/xmlReportElement.cxx
+++ b/reportdesign/source/filter/xml/xmlReportElement.cxx
@@ -26,6 +26,7 @@
#include "xmlCondPrtExpr.hxx"
#include "xmlFormatCondition.hxx"
#include <osl/diagnose.h>
+#include <sal/log.hxx>
namespace rptxml
{
diff --git a/reportdesign/source/filter/xml/xmlSection.cxx b/reportdesign/source/filter/xml/xmlSection.cxx
index fb7d44398430..5e1c47e1869c 100644
--- a/reportdesign/source/filter/xml/xmlSection.cxx
+++ b/reportdesign/source/filter/xml/xmlSection.cxx
@@ -25,6 +25,7 @@
#include <com/sun/star/report/ReportPrintOption.hpp>
#include "xmlTable.hxx"
#include <osl/diagnose.h>
+#include <sal/log.hxx>
namespace rptxml
diff --git a/reportdesign/source/filter/xml/xmlTable.cxx b/reportdesign/source/filter/xml/xmlTable.cxx
index 55179cc83f95..55c44df062c2 100644
--- a/reportdesign/source/filter/xml/xmlTable.cxx
+++ b/reportdesign/source/filter/xml/xmlTable.cxx
@@ -35,6 +35,7 @@
#include <com/sun/star/report/XShape.hpp>
#include <com/sun/star/report/XFixedLine.hpp>
#include <osl/diagnose.h>
+#include <sal/log.hxx>
#include <numeric>
diff --git a/xmloff/source/core/xmlictxt.cxx b/xmloff/source/core/xmlictxt.cxx
index 5c75a964caef..175adf28c876 100644
--- a/xmloff/source/core/xmlictxt.cxx
+++ b/xmloff/source/core/xmlictxt.cxx
@@ -144,9 +144,4 @@ css::uno::Sequence< sal_Int8 > SAL_CALL SvXMLImportContext::getImplementationId(
return css::uno::Sequence<sal_Int8>();
}
-void XMLOFF_WARN_UNKNOWN(const char *area, sax_fastparser::FastAttributeList::FastAttributeIter const & rIter)
-{
- SAL_WARN(area, "unknown attribute " << SvXMLImport::getPrefixAndNameFromToken(rIter.getToken()) << " value=" << rIter.toString());
-}
-
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */