Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
Akonadi Search
Commits
d7ce65df
Commit
d7ce65df
authored
Aug 23, 2020
by
Laurent Montel
😁
Browse files
Use toStdString
parent
8e19cd18
Pipeline
#31452
passed with stage
in 22 minutes and 18 seconds
Changes
5
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
agent/akonotesindexer.cpp
View file @
d7ce65df
...
...
@@ -14,7 +14,7 @@ AkonotesIndexer::AkonotesIndexer(const QString &path)
:
AbstractIndexer
()
{
try
{
m_db
=
new
Xapian
::
WritableDatabase
(
path
.
to
Utf8
().
constData
(),
Xapian
::
DB_CREATE_OR_OPEN
);
m_db
=
new
Xapian
::
WritableDatabase
(
path
.
to
StdString
(),
Xapian
::
DB_CREATE_OR_OPEN
);
}
catch
(
const
Xapian
::
DatabaseCorruptError
&
err
)
{
qCWarning
(
AKONADI_INDEXER_AGENT_LOG
)
<<
"Database Corrupted - What did you do?"
;
qCWarning
(
AKONADI_INDEXER_AGENT_LOG
)
<<
err
.
get_error_string
();
...
...
agent/collectionindexer.cpp
View file @
d7ce65df
...
...
@@ -22,7 +22,7 @@ CollectionIndexer::CollectionIndexer(const QString &path)
Akonadi
::
AttributeFactory
::
registerAttribute
<
Akonadi
::
CollectionIdentificationAttribute
>
();
try
{
m_db
=
new
Xapian
::
WritableDatabase
(
path
.
to
Utf8
().
constData
(),
Xapian
::
DB_CREATE_OR_OPEN
);
m_db
=
new
Xapian
::
WritableDatabase
(
path
.
to
StdString
(),
Xapian
::
DB_CREATE_OR_OPEN
);
}
catch
(
const
Xapian
::
DatabaseCorruptError
&
err
)
{
qCCritical
(
AKONADI_INDEXER_AGENT_LOG
)
<<
"Database Corrupted - What did you do?"
;
qCCritical
(
AKONADI_INDEXER_AGENT_LOG
)
<<
err
.
get_error_string
();
...
...
agent/emailindexer.cpp
View file @
d7ce65df
...
...
@@ -18,7 +18,7 @@ EmailIndexer::EmailIndexer(const QString &path, const QString &contactDbPath)
:
AbstractIndexer
()
{
try
{
m_db
=
new
Xapian
::
WritableDatabase
(
path
.
to
Utf8
().
constData
(),
Xapian
::
DB_CREATE_OR_OPEN
);
m_db
=
new
Xapian
::
WritableDatabase
(
path
.
to
StdString
(),
Xapian
::
DB_CREATE_OR_OPEN
);
}
catch
(
const
Xapian
::
DatabaseCorruptError
&
err
)
{
qCWarning
(
AKONADI_INDEXER_AGENT_LOG
)
<<
"Database Corrupted - What did you do?"
;
qCWarning
(
AKONADI_INDEXER_AGENT_LOG
)
<<
err
.
get_error_string
();
...
...
@@ -29,7 +29,7 @@ EmailIndexer::EmailIndexer(const QString &path, const QString &contactDbPath)
}
try
{
m_contactDb
=
new
Xapian
::
WritableDatabase
(
contactDbPath
.
to
Utf8
().
constData
(),
Xapian
::
DB_CREATE_OR_OPEN
);
m_contactDb
=
new
Xapian
::
WritableDatabase
(
contactDbPath
.
to
StdString
(),
Xapian
::
DB_CREATE_OR_OPEN
);
}
catch
(
const
Xapian
::
DatabaseCorruptError
&
err
)
{
qCWarning
(
AKONADI_INDEXER_AGENT_LOG
)
<<
"Database Corrupted - What did you do?"
;
qCWarning
(
AKONADI_INDEXER_AGENT_LOG
)
<<
err
.
get_error_string
();
...
...
xapian/xapiandatabase.cpp
View file @
d7ce65df
...
...
@@ -24,7 +24,7 @@ XapianDatabase::XapianDatabase(const QString &path, bool writeOnly)
:
m_writeOnly
(
writeOnly
)
{
QDir
().
mkpath
(
path
);
m_path
=
path
.
to
Utf8
().
constData
();
m_path
=
path
.
to
StdString
();
if
(
!
writeOnly
)
{
try
{
...
...
xapian/xapiansearchstore.cpp
View file @
d7ce65df
...
...
@@ -39,7 +39,7 @@ void XapianSearchStore::setDbPath(const QString &path)
m_db
=
nullptr
;
try
{
m_db
=
new
Xapian
::
Database
(
m_dbPath
.
to
Utf8
().
constData
());
m_db
=
new
Xapian
::
Database
(
m_dbPath
.
to
StdString
());
}
catch
(
const
Xapian
::
DatabaseOpeningError
&
)
{
qCWarning
(
AKONADI_SEARCH_XAPIAN_LOG
)
<<
"Xapian Database does not exist at "
<<
m_dbPath
;
}
catch
(
const
Xapian
::
DatabaseCorruptError
&
)
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment