summaryrefslogtreecommitdiff
path: root/plugins/Import
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/Import')
-rw-r--r--plugins/Import/src/mcontacts.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/plugins/Import/src/mcontacts.cpp b/plugins/Import/src/mcontacts.cpp
index c9d843aa34..2def8eefce 100644
--- a/plugins/Import/src/mcontacts.cpp
+++ b/plugins/Import/src/mcontacts.cpp
@@ -241,6 +241,9 @@ public:
STDMETHODIMP_(MEVENT) FindFirstEvent(MCONTACT) override
{
+ if (m_events.empty())
+ return 0;
+
m_curr = m_events.begin();
return *m_curr;
}
@@ -256,6 +259,9 @@ public:
STDMETHODIMP_(MEVENT) FindLastEvent(MCONTACT) override
{
+ if (m_events.empty())
+ return 0;
+
m_curr = m_events.end();
return *m_curr;
}