source config: improved error message

An invalid syncFormat (like text/vcard for "Evolution Calendar")
can prevent instantiating the source. Therefore include that
value in the error message and clearly distinguish between
sync and database format.
This commit is contained in:
Patrick Ohly 2011-08-10 15:07:18 +02:00
parent 6ce041fba8
commit 4424c38548
1 changed files with 3 additions and 2 deletions

View File

@ -357,11 +357,12 @@ SyncSource *SyncSource::createSource(const SyncSourceParams &params, bool error,
backends += ") ";
}
string problem =
StringPrintf("%s: backend '%s' not supported %sor not fully configured (format '%s')",
StringPrintf("%s: backend '%s' not supported %sor not correctly configured (databaseFormat '%s', syncFormat '%s')",
params.m_name.c_str(),
sourceType.m_backend.c_str(),
backends.c_str(),
sourceType.m_localFormat.c_str());
sourceType.m_localFormat.c_str(),
sourceType.m_format.c_str());
SyncContext::throwError(problem);
}