summaryrefslogtreecommitdiffstats
path: root/i18npool/source
diff options
context:
space:
mode:
authorJulien Nabet <serval2412@yahoo.fr>2020-06-11 19:04:18 +0200
committerXisco Fauli <xiscofauli@libreoffice.org>2020-06-16 13:13:58 +0200
commitbca5d96335fd3742b721e99b10934502b105259a (patch)
treea99344dfe1579ea6824c4efea2e125a167310261 /i18npool/source
parentfix my own mistake (diff)
downloadcore-bca5d96335fd3742b721e99b10934502b105259a.tar.gz
core-bca5d96335fd3742b721e99b10934502b105259a.zip
tdf#133898: get a context in default ctr (i18npool/calendarImpl)
See bt here: https://bugs.documentfoundation.org/attachment.cgi?id=161882 Change-Id: If5a6c5e2b52af9ef97af9522296aaa58352cfa69 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/96161 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Reviewed-by: Julien Nabet <serval2412@yahoo.fr> (cherry picked from commit 56e2183b4916888fa104b62411151401932d8f92) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/96179 Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Diffstat (limited to 'i18npool/source')
-rw-r--r--i18npool/source/calendar/calendarImpl.cxx7
1 files changed, 7 insertions, 0 deletions
diff --git a/i18npool/source/calendar/calendarImpl.cxx b/i18npool/source/calendar/calendarImpl.cxx
index 2cb659560489..8a288bcb6c31 100644
--- a/i18npool/source/calendar/calendarImpl.cxx
+++ b/i18npool/source/calendar/calendarImpl.cxx
@@ -20,6 +20,7 @@
#include <calendarImpl.hxx>
#include <calendar_gregorian.hxx>
#include <localedata.hxx>
+#include <comphelper/processfactory.hxx>
#include <comphelper/sequence.hxx>
#include <cppuhelper/supportsservice.hxx>
@@ -32,8 +33,14 @@ namespace i18npool {
#define ERROR RuntimeException()
+CalendarImpl::CalendarImpl() : m_xContext(comphelper::getProcessComponentContext())
+{
+}
+
CalendarImpl::CalendarImpl(const Reference< XComponentContext > &rxContext) : m_xContext(rxContext)
{
+ if (!m_xContext.is())
+ throw ERROR;
}
CalendarImpl::~CalendarImpl()