summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSandro Knauß <[email protected]>2016-03-21 13:37:55 +0100
committerSandro Knauß <[email protected]>2016-03-21 14:18:17 +0100
commitbdb63e8ca160363483cdd773d7e4934daeaad138 (patch)
tree14eb60c6c59d6587a4540931bc61314f7f3ea4ed
parent75a72bed4a365acad7c2b7b503fb2d5449823c72 (diff)
Move logging category to mimetreeparser
-rw-r--r--mimetreeparser/src/CMakeLists.txt2
-rw-r--r--mimetreeparser/src/htmlwriter/filehtmlwriter.cpp8
-rw-r--r--mimetreeparser/src/htmlwriter/queuehtmlwriter.cpp2
-rw-r--r--mimetreeparser/src/job/kleojobexecutor.cpp14
-rw-r--r--mimetreeparser/src/utils/mimetype.cpp4
-rw-r--r--mimetreeparser/src/viewer/attachmentstrategy.cpp4
-rw-r--r--mimetreeparser/src/viewer/bodypartformatter.cpp4
-rw-r--r--mimetreeparser/src/viewer/bodypartformatterbasefactory.cpp8
-rw-r--r--mimetreeparser/src/viewer/memento/verifydetachedbodypartmemento.cpp20
-rw-r--r--mimetreeparser/src/viewer/memento/verifyopaquebodypartmemento.cpp20
-rw-r--r--mimetreeparser/src/viewer/messagepart.cpp18
-rw-r--r--mimetreeparser/src/viewer/nodehelper.cpp50
-rw-r--r--mimetreeparser/src/viewer/objecttreeparser.cpp62
-rw-r--r--mimetreeparser/src/viewer/partnodebodypart.cpp4
14 files changed, 109 insertions, 111 deletions
diff --git a/mimetreeparser/src/CMakeLists.txt b/mimetreeparser/src/CMakeLists.txt
index 0366797..ff4638e 100644
--- a/mimetreeparser/src/CMakeLists.txt
+++ b/mimetreeparser/src/CMakeLists.txt
@@ -125,8 +125,6 @@ set(libmimetreeparser_SRCS
${libmimetreeparser_extra_SRCS}
)
-ecm_qt_declare_logging_category(libmimetreeparser_SRCS HEADER messageviewer_debug.h IDENTIFIER MESSAGEVIEWER_LOG CATEGORY_NAME log_messageviewer)
-
ecm_qt_declare_logging_category(libmimetreeparser_SRCS HEADER mimetreeparser_debug.h IDENTIFIER MIMETREEPARSER_LOG CATEGORY_NAME log_mimetreeparser)
add_library(KF5MimeTreeParser
diff --git a/mimetreeparser/src/htmlwriter/filehtmlwriter.cpp b/mimetreeparser/src/htmlwriter/filehtmlwriter.cpp
index 6e1c848..ecb148c 100644
--- a/mimetreeparser/src/htmlwriter/filehtmlwriter.cpp
+++ b/mimetreeparser/src/htmlwriter/filehtmlwriter.cpp
@@ -31,7 +31,7 @@
#include "filehtmlwriter.h"
-#include "messageviewer_debug.h"
+#include "mimetreeparser_debug.h"
namespace MessageViewer
{
@@ -46,7 +46,7 @@ FileHtmlWriter::FileHtmlWriter(const QString &filename)
FileHtmlWriter::~FileHtmlWriter()
{
if (mFile.isOpen()) {
- qCWarning(MESSAGEVIEWER_LOG) << "FileHtmlWriter: file still open!";
+ qCWarning(MIMETREEPARSER_LOG) << "FileHtmlWriter: file still open!";
mStream.setDevice(0);
mFile.close();
}
@@ -95,12 +95,12 @@ void FileHtmlWriter::flush()
void FileHtmlWriter::openOrWarn()
{
if (mFile.isOpen()) {
- qCWarning(MESSAGEVIEWER_LOG) << "FileHtmlWriter: file still open!";
+ qCWarning(MIMETREEPARSER_LOG) << "FileHtmlWriter: file still open!";
mStream.setDevice(0);
mFile.close();
}
if (!mFile.open(QIODevice::WriteOnly)) {
- qCWarning(MESSAGEVIEWER_LOG) << "FileHtmlWriter: Cannot open file" << mFile.fileName();
+ qCWarning(MIMETREEPARSER_LOG) << "FileHtmlWriter: Cannot open file" << mFile.fileName();
} else {
mStream.setDevice(&mFile);
}
diff --git a/mimetreeparser/src/htmlwriter/queuehtmlwriter.cpp b/mimetreeparser/src/htmlwriter/queuehtmlwriter.cpp
index 10ab21b..f8c802c 100644
--- a/mimetreeparser/src/htmlwriter/queuehtmlwriter.cpp
+++ b/mimetreeparser/src/htmlwriter/queuehtmlwriter.cpp
@@ -19,7 +19,7 @@
#include "queuehtmlwriter.h"
-#include "messageviewer_debug.h"
+#include "mimetreeparser_debug.h"
#include<QByteArray>
#include<QString>
diff --git a/mimetreeparser/src/job/kleojobexecutor.cpp b/mimetreeparser/src/job/kleojobexecutor.cpp
index cd4fd26..553a443 100644
--- a/mimetreeparser/src/job/kleojobexecutor.cpp
+++ b/mimetreeparser/src/job/kleojobexecutor.cpp
@@ -17,7 +17,7 @@
*/
#include "kleojobexecutor.h"
-#include "messageviewer_debug.h"
+#include "mimetreeparser_debug.h"
#include <Libkleo/DecryptVerifyJob>
#include <Libkleo/ImportJob>
#include <Libkleo/VerifyDetachedJob>
@@ -43,7 +43,7 @@ GpgME::VerificationResult KleoJobExecutor::exec(
const QByteArray &signature,
const QByteArray &signedData)
{
- qCDebug(MESSAGEVIEWER_LOG) << "Starting detached verification job";
+ qCDebug(MIMETREEPARSER_LOG) << "Starting detached verification job";
connect(job, SIGNAL(result(GpgME::VerificationResult)), SLOT(verificationResult(GpgME::VerificationResult)));
GpgME::Error err = job->start(signature, signedData);
if (err) {
@@ -58,7 +58,7 @@ GpgME::VerificationResult KleoJobExecutor::exec(
const QByteArray &signedData,
QByteArray &plainText)
{
- qCDebug(MESSAGEVIEWER_LOG) << "Starting opaque verification job";
+ qCDebug(MIMETREEPARSER_LOG) << "Starting opaque verification job";
connect(job, SIGNAL(result(GpgME::VerificationResult,QByteArray)), SLOT(verificationResult(GpgME::VerificationResult,QByteArray)));
GpgME::Error err = job->start(signedData);
if (err) {
@@ -75,7 +75,7 @@ std::pair< GpgME::DecryptionResult, GpgME::VerificationResult > KleoJobExecutor:
const QByteArray &cipherText,
QByteArray &plainText)
{
- qCDebug(MESSAGEVIEWER_LOG) << "Starting decryption job";
+ qCDebug(MIMETREEPARSER_LOG) << "Starting decryption job";
connect(job, &DecryptVerifyJob::result, this, &KleoJobExecutor::decryptResult);
GpgME::Error err = job->start(cipherText);
if (err) {
@@ -105,7 +105,7 @@ Error KleoJobExecutor::auditLogError() const
void KleoJobExecutor::verificationResult(const GpgME::VerificationResult &result)
{
- qCDebug(MESSAGEVIEWER_LOG) << "Detached verification job finished";
+ qCDebug(MIMETREEPARSER_LOG) << "Detached verification job finished";
Kleo::Job *job = dynamic_cast<Kleo::Job *>(sender());
assert(job);
mVerificationResult = result;
@@ -116,7 +116,7 @@ void KleoJobExecutor::verificationResult(const GpgME::VerificationResult &result
void KleoJobExecutor::verificationResult(const GpgME::VerificationResult &result, const QByteArray &plainText)
{
- qCDebug(MESSAGEVIEWER_LOG) << "Opaque verification job finished";
+ qCDebug(MIMETREEPARSER_LOG) << "Opaque verification job finished";
Kleo::Job *job = dynamic_cast<Kleo::Job *>(sender());
assert(job);
mVerificationResult = result;
@@ -131,7 +131,7 @@ void KleoJobExecutor::decryptResult(
const GpgME::VerificationResult &verificationresult,
const QByteArray &plainText)
{
- qCDebug(MESSAGEVIEWER_LOG) << "Decryption job finished";
+ qCDebug(MIMETREEPARSER_LOG) << "Decryption job finished";
Kleo::Job *job = dynamic_cast<Kleo::Job *>(sender());
assert(job);
mVerificationResult = verificationresult;
diff --git a/mimetreeparser/src/utils/mimetype.cpp b/mimetreeparser/src/utils/mimetype.cpp
index afd1008..b4cb355 100644
--- a/mimetreeparser/src/utils/mimetype.cpp
+++ b/mimetreeparser/src/utils/mimetype.cpp
@@ -19,7 +19,7 @@
#include "utils/mimetype.h"
#include "utils/iconnamecache.h"
-#include "messageviewer_debug.h"
+#include "mimetreeparser_debug.h"
#include <QMimeDatabase>
@@ -65,7 +65,7 @@ QString MessageViewer::Util::fileNameForMimetype(const QString &mimeType, int ic
} else {
fileName = QStringLiteral("unknown");
if (!tMimeType.isEmpty()) {
- qCWarning(MESSAGEVIEWER_LOG) << "unknown mimetype" << tMimeType;
+ qCWarning(MIMETREEPARSER_LOG) << "unknown mimetype" << tMimeType;
}
}
//WorkAround for #199083
diff --git a/mimetreeparser/src/viewer/attachmentstrategy.cpp b/mimetreeparser/src/viewer/attachmentstrategy.cpp
index a98c1f8..ee1daf2 100644
--- a/mimetreeparser/src/viewer/attachmentstrategy.cpp
+++ b/mimetreeparser/src/viewer/attachmentstrategy.cpp
@@ -37,7 +37,7 @@
#include <KMime/Content>
-#include "messageviewer_debug.h"
+#include "mimetreeparser_debug.h"
namespace MessageViewer
{
@@ -266,7 +266,7 @@ const AttachmentStrategy *AttachmentStrategy::create(Type type)
case Hidden: return hidden();
case HeaderOnly: return headerOnly();
}
- qCCritical(MESSAGEVIEWER_LOG) << "Unknown attachment startegy ( type =="
+ qCCritical(MIMETREEPARSER_LOG) << "Unknown attachment startegy ( type =="
<< (int)type << ") requested!";
return 0; // make compiler happy
}
diff --git a/mimetreeparser/src/viewer/bodypartformatter.cpp b/mimetreeparser/src/viewer/bodypartformatter.cpp
index d37a497..18a5f20 100644
--- a/mimetreeparser/src/viewer/bodypartformatter.cpp
+++ b/mimetreeparser/src/viewer/bodypartformatter.cpp
@@ -29,7 +29,7 @@
your version.
*/
-#include "messageviewer_debug.h"
+#include "mimetreeparser_debug.h"
#include "bodypartformatterbasefactory.h"
#include "viewer/bodypartformatterbasefactory_p.h"
@@ -53,7 +53,7 @@ class AnyTypeBodyPartFormatter
public:
Result format(Interface::BodyPart *, HtmlWriter *) const Q_DECL_OVERRIDE
{
- qCDebug(MESSAGEVIEWER_LOG) << "Acting as a Interface::BodyPartFormatter!";
+ qCDebug(MIMETREEPARSER_LOG) << "Acting as a Interface::BodyPartFormatter!";
return AsIcon;
}
diff --git a/mimetreeparser/src/viewer/bodypartformatterbasefactory.cpp b/mimetreeparser/src/viewer/bodypartformatterbasefactory.cpp
index 556106c..3554459 100644
--- a/mimetreeparser/src/viewer/bodypartformatterbasefactory.cpp
+++ b/mimetreeparser/src/viewer/bodypartformatterbasefactory.cpp
@@ -33,7 +33,7 @@
#include "bodypartformatterbasefactory.h"
#include "bodypartformatterbasefactory_p.h"
-#include "messageviewer_debug.h"
+#include "mimetreeparser_debug.h"
// Qt
#include <QString>
@@ -73,7 +73,7 @@ void BodyPartFormatterBaseFactoryPrivate::insert(const char *type, const char *s
TypeRegistry::iterator type_it = all->find(type);
if (type_it == all->end()) {
- qCDebug(MESSAGEVIEWER_LOG) << "BodyPartFormatterBaseFactory: instantiating new Subtype Registry for \""
+ qCDebug(MIMETREEPARSER_LOG) << "BodyPartFormatterBaseFactory: instantiating new Subtype Registry for \""
<< type << "\"";
type_it = all->insert(std::make_pair(type, SubtypeRegistry())).first;
assert(type_it != all->end());
@@ -166,7 +166,7 @@ SubtypeRegistry::const_iterator BodyPartFormatterBaseFactory::createForIterator(
}
if (!(*subtype_it).second) {
- qCWarning(MESSAGEVIEWER_LOG) << "BodyPartFormatterBaseFactory: a null bodypart formatter sneaked in for \""
+ qCWarning(MIMETREEPARSER_LOG) << "BodyPartFormatterBaseFactory: a null bodypart formatter sneaked in for \""
<< type << "/" << subtype << "\"!";
}
@@ -194,5 +194,5 @@ const Interface::BodyPartFormatter *BodyPartFormatterBaseFactory::createFor(cons
void BodyPartFormatterBaseFactory::loadPlugins()
{
- qCDebug(MESSAGEVIEWER_LOG) << "plugin loading is not enabled in libotp";
+ qCDebug(MIMETREEPARSER_LOG) << "plugin loading is not enabled in libotp";
}
diff --git a/mimetreeparser/src/viewer/memento/verifydetachedbodypartmemento.cpp b/mimetreeparser/src/viewer/memento/verifydetachedbodypartmemento.cpp
index e2bf139..0e5a862 100644
--- a/mimetreeparser/src/viewer/memento/verifydetachedbodypartmemento.cpp
+++ b/mimetreeparser/src/viewer/memento/verifydetachedbodypartmemento.cpp
@@ -16,7 +16,7 @@
*/
#include "verifydetachedbodypartmemento.h"
-#include "messageviewer_debug.h"
+#include "mimetreeparser_debug.h"
#include <Libkleo/VerifyDetachedJob>
#include <Libkleo/KeyListJob>
@@ -58,14 +58,14 @@ bool VerifyDetachedBodyPartMemento::start()
{
assert(m_job);
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyDetachedBodyPartMemento started";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyDetachedBodyPartMemento started";
#endif
connect(m_job, SIGNAL(result(GpgME::VerificationResult)),
this, SLOT(slotResult(GpgME::VerificationResult)));
if (const Error err = m_job->start(m_signature, m_plainText)) {
m_vr = VerificationResult(err);
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyDetachedBodyPartMemento stopped with error";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyDetachedBodyPartMemento stopped with error";
#endif
return false;
}
@@ -78,13 +78,13 @@ void VerifyDetachedBodyPartMemento::exec()
assert(m_job);
setRunning(true);
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyDetachedBodyPartMemento execed";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyDetachedBodyPartMemento execed";
#endif
saveResult(m_job->exec(m_signature, m_plainText));
m_job->deleteLater(); // exec'ed jobs don't delete themselves
m_job = 0;
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyDetachedBodyPartMemento after execed";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyDetachedBodyPartMemento after execed";
#endif
if (canStartKeyListJob()) {
std::vector<GpgME::Key> keys;
@@ -119,7 +119,7 @@ void VerifyDetachedBodyPartMemento::saveResult(const VerificationResult &vr)
{
assert(m_job);
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyDetachedBodyPartMemento::saveResult called";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyDetachedBodyPartMemento::saveResult called";
#endif
m_vr = vr;
setAuditLog(m_job->auditLogError(), m_job->auditLogAsHtml());
@@ -128,13 +128,13 @@ void VerifyDetachedBodyPartMemento::saveResult(const VerificationResult &vr)
void VerifyDetachedBodyPartMemento::slotResult(const VerificationResult &vr)
{
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyDetachedBodyPartMemento::slotResult called";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyDetachedBodyPartMemento::slotResult called";
#endif
saveResult(vr);
m_job = 0;
if (canStartKeyListJob() && startKeyListJob()) {
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyDetachedBodyPartMemento: canStartKeyListJob && startKeyListJob";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyDetachedBodyPartMemento: canStartKeyListJob && startKeyListJob";
#endif
return;
}
@@ -161,7 +161,7 @@ bool VerifyDetachedBodyPartMemento::startKeyListJob()
void VerifyDetachedBodyPartMemento::slotNextKey(const GpgME::Key &key)
{
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyDetachedBodyPartMemento::slotNextKey called";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyDetachedBodyPartMemento::slotNextKey called";
#endif
m_key = key;
}
@@ -169,7 +169,7 @@ void VerifyDetachedBodyPartMemento::slotNextKey(const GpgME::Key &key)
void VerifyDetachedBodyPartMemento::slotKeyListJobDone()
{
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyDetachedBodyPartMemento::slotKeyListJobDone called";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyDetachedBodyPartMemento::slotKeyListJobDone called";
#endif
m_keylistjob = 0;
setRunning(false);
diff --git a/mimetreeparser/src/viewer/memento/verifyopaquebodypartmemento.cpp b/mimetreeparser/src/viewer/memento/verifyopaquebodypartmemento.cpp
index c9be2cc..4a426dd 100644
--- a/mimetreeparser/src/viewer/memento/verifyopaquebodypartmemento.cpp
+++ b/mimetreeparser/src/viewer/memento/verifyopaquebodypartmemento.cpp
@@ -16,7 +16,7 @@
*/
#include "verifyopaquebodypartmemento.h"
-#include "messageviewer_debug.h"
+#include "mimetreeparser_debug.h"
#include <Libkleo/VerifyOpaqueJob>
#include <Libkleo/KeyListJob>
@@ -56,12 +56,12 @@ bool VerifyOpaqueBodyPartMemento::start()
{
assert(m_job);
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento started";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento started";
#endif
if (const Error err = m_job->start(m_signature)) {
m_vr = VerificationResult(err);
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento stopped with error";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento stopped with error";
#endif
return false;
}
@@ -77,11 +77,11 @@ void VerifyOpaqueBodyPartMemento::exec()
setRunning(true);
QByteArray plainText;
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento execed";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento execed";
#endif
saveResult(m_job->exec(m_signature, plainText), plainText);
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento after execed";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento after execed";
#endif
m_job->deleteLater(); // exec'ed jobs don't delete themselves
m_job = 0;
@@ -119,7 +119,7 @@ void VerifyOpaqueBodyPartMemento::saveResult(const VerificationResult &vr,
{
assert(m_job);
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento::saveResult called";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento::saveResult called";
#endif
m_vr = vr;
m_plainText = plainText;
@@ -130,13 +130,13 @@ void VerifyOpaqueBodyPartMemento::slotResult(const VerificationResult &vr,
const QByteArray &plainText)
{
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento::slotResult called";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento::slotResult called";
#endif
saveResult(vr, plainText);
m_job = 0;
if (canStartKeyListJob() && startKeyListJob()) {
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento: canStartKeyListJob && startKeyListJob";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento: canStartKeyListJob && startKeyListJob";
#endif
return;
}
@@ -163,7 +163,7 @@ bool VerifyOpaqueBodyPartMemento::startKeyListJob()
void VerifyOpaqueBodyPartMemento::slotNextKey(const GpgME::Key &key)
{
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento::slotNextKey called";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento::slotNextKey called";
#endif
m_key = key;
}
@@ -171,7 +171,7 @@ void VerifyOpaqueBodyPartMemento::slotNextKey(const GpgME::Key &key)
void VerifyOpaqueBodyPartMemento::slotKeyListJobDone()
{
#ifdef DEBUG_SIGNATURE
- qCDebug(MESSAGEVIEWER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento::slotKeyListJobDone called";
+ qCDebug(MIMETREEPARSER_LOG) << "tokoe: VerifyOpaqueBodyPartMemento::slotKeyListJobDone called";
#endif
m_keylistjob = 0;
setRunning(false);
diff --git a/mimetreeparser/src/viewer/messagepart.cpp b/mimetreeparser/src/viewer/messagepart.cpp
index 0c0eb2f..c1b5355 100644
--- a/mimetreeparser/src/viewer/messagepart.cpp
+++ b/mimetreeparser/src/viewer/messagepart.cpp
@@ -18,7 +18,7 @@
*/
#include "messagepart.h"
-#include "messageviewer_debug.h"
+#include "mimetreeparser_debug.h"
#include "objecttreeparser.h"
#include "converthtmltoplaintext.h"
#include "csshelperbase.h"
@@ -497,10 +497,10 @@ static QString makeShowAuditLogLink(const GpgME::Error &err, const QString &audi
// equally applies there:
if (const unsigned int code = err.code()) {
if (code == GPG_ERR_NOT_IMPLEMENTED) {
- qCDebug(MESSAGEVIEWER_LOG) << "not showing link (not implemented)";
+ qCDebug(MIMETREEPARSER_LOG) << "not showing link (not implemented)";
return QString();
} else if (code == GPG_ERR_NO_DATA) {
- qCDebug(MESSAGEVIEWER_LOG) << "not showing link (not available)";
+ qCDebug(MIMETREEPARSER_LOG) << "not showing link (not available)";
return i18n("No Audit Log available");
} else {
return i18n("Error Retrieving Audit Log: %1", QString::fromLocal8Bit(err.asString()));
@@ -1236,7 +1236,7 @@ TextMessagePart::TextMessagePart(ObjectTreeParser *otp, KMime::Content *node, bo
, mAsIcon(asIcon)
{
if (!mNode) {
- qCWarning(MESSAGEVIEWER_LOG) << "not a valid node";
+ qCWarning(MIMETREEPARSER_LOG) << "not a valid node";
return;
}
@@ -1373,7 +1373,7 @@ HtmlMessagePart::HtmlMessagePart(ObjectTreeParser *otp, KMime::Content *node, Ob
, mSource(source)
{
if (!mNode) {
- qCWarning(MESSAGEVIEWER_LOG) << "not a valid node";
+ qCWarning(MIMETREEPARSER_LOG) << "not a valid node";
return;
}
@@ -1481,7 +1481,7 @@ MimeMessagePart::MimeMessagePart(ObjectTreeParser *otp, KMime::Content *node, bo
, mOnlyOneMimePart(onlyOneMimePart)
{
if (!mNode) {
- qCWarning(MESSAGEVIEWER_LOG) << "not a valid node";
+ qCWarning(MIMETREEPARSER_LOG) << "not a valid node";
return;
}
@@ -1513,7 +1513,7 @@ AlternativeMessagePart::AlternativeMessagePart(ObjectTreeParser *otp, KMime::Con
, mViewHtml(false)
{
if (!mTextNode && !mHTMLNode) {
- qCWarning(MESSAGEVIEWER_LOG) << "not a valid nodes";
+ qCWarning(MIMETREEPARSER_LOG) << "not a valid nodes";
return;
}
@@ -1597,7 +1597,7 @@ CertMessagePart::CertMessagePart(ObjectTreeParser *otp, KMime::Content *node, co
, mCryptoProto(cryptoProto)
{
if (!mNode) {
- qCWarning(MESSAGEVIEWER_LOG) << "not a valid node";
+ qCWarning(MIMETREEPARSER_LOG) << "not a valid node";
return;
}
@@ -1882,7 +1882,7 @@ EncapsulatedRfc822MessagePart::EncapsulatedRfc822MessagePart(ObjectTreeParser *o
mOtp->nodeHelper()->setPartMetaData(mNode, mMetaData);
if (!mMessage) {
- qCWarning(MESSAGEVIEWER_LOG) << "Node is of type message/rfc822 but doesn't have a message!";
+ qCWarning(MIMETREEPARSER_LOG) << "Node is of type message/rfc822 but doesn't have a message!";
return;
}
diff --git a/mimetreeparser/src/viewer/nodehelper.cpp b/mimetreeparser/src/viewer/nodehelper.cpp
index de90ad3..872b4bd 100644
--- a/mimetreeparser/src/viewer/nodehelper.cpp
+++ b/mimetreeparser/src/viewer/nodehelper.cpp
@@ -18,7 +18,7 @@
*/
#include "nodehelper.h"
-#include "messageviewer_debug.h"
+#include "mimetreeparser_debug.h"
#include "utils/iconnamecache.h"
#include "partmetadata.h"
#include "interfaces/bodypart.h"
@@ -97,7 +97,7 @@ void NodeHelper::setNodeProcessed(KMime::Content *node, bool recurse)
return;
}
mProcessedNodes.append(node);
- qCDebug(MESSAGEVIEWER_LOG) << "Node processed: " << node->index().toString() << node->contentType()->as7BitString();
+ qCDebug(MIMETREEPARSER_LOG) << "Node processed: " << node->index().toString() << node->contentType()->as7BitString();
//<< " decodedContent" << node->decodedContent();
if (recurse) {
auto contents = node->contents();
@@ -124,11 +124,11 @@ void NodeHelper::setNodeUnprocessed(KMime::Content *node, bool recurse)
}
}
qDeleteAll(it.value());
- qCDebug(MESSAGEVIEWER_LOG) << "mExtraContents deleted for" << it.key();
+ qCDebug(MIMETREEPARSER_LOG) << "mExtraContents deleted for" << it.key();
mExtraContents.erase(it);
}
- qCDebug(MESSAGEVIEWER_LOG) << "Node UNprocessed: " << node;
+ qCDebug(MIMETREEPARSER_LOG) << "Node UNprocessed: " << node;
if (recurse) {
auto contents = node->contents();
Q_FOREACH (KMime::Content *c, contents) {
@@ -176,7 +176,7 @@ void NodeHelper::clear()
}
}
qDeleteAll(it.value());
- qCDebug(MESSAGEVIEWER_LOG) << "mExtraContents deleted for" << it.key();
+ qCDebug(MIMETREEPARSER_LOG) << "mExtraContents deleted for" << it.key();
}
mExtraContents.clear();
mDisplayEmbeddedNodes.clear();
@@ -239,7 +239,7 @@ QString NodeHelper::writeNodeToTempFile(KMime::Content *node)
}
fname += QLatin1Char('/') + fileName;
- qCDebug(MESSAGEVIEWER_LOG) << "Create temp file: " << fname;
+ qCDebug(MIMETREEPARSER_LOG) << "Create temp file: " << fname;
QByteArray data = node->decodedContent();
if (node->contentType()->isText() && data.size() > 0) {
// convert CRLF to LF before writing text attachments to disk
@@ -247,7 +247,7 @@ QString NodeHelper::writeNodeToTempFile(KMime::Content *node)
}
QFile f(fname);
if (!f.open(QIODevice::ReadWrite)) {
- qCWarning(MESSAGEVIEWER_LOG) << "Failed to write note to file:" << f.errorString();
+ qCWarning(MIMETREEPARSER_LOG) << "Failed to write note to file:" << f.errorString();
return QString();
}
f.write(data);
@@ -393,7 +393,7 @@ KMMsgEncryptionState NodeHelper::overallEncryptionState(KMime::Content *node) co
}
}
- qCDebug(MESSAGEVIEWER_LOG) << "\n\n KMMsgEncryptionState:" << myState;
+ qCDebug(MIMETREEPARSER_LOG) << "\n\n KMMsgEncryptionState:" << myState;
return myState;
}
@@ -443,7 +443,7 @@ KMMsgSignatureState NodeHelper::overallSignatureState(KMime::Content *node) cons
}
}
- qCDebug(MESSAGEVIEWER_LOG) << "\n\n KMMsgSignatureState:" << myState;
+ qCDebug(MIMETREEPARSER_LOG) << "\n\n KMMsgSignatureState:" << myState;
return myState;
}
@@ -488,7 +488,7 @@ QString NodeHelper::replacePrefixes(const QString &str,
.arg(prefixRegExps.join(QStringLiteral(")|(?:")));
QRegExp rx(bigRegExp, Qt::CaseInsensitive);
if (!rx.isValid()) {
- qCWarning(MESSAGEVIEWER_LOG) << "bigRegExp = \""
+ qCWarning(MIMETREEPARSER_LOG) << "bigRegExp = \""
<< bigRegExp << "\"\n"
<< "prefix regexp is invalid!";
// try good ole Re/Fwd:
@@ -615,13 +615,13 @@ void NodeHelper::setBodyPartMemento(KMime::Content *node, const QByteArray &whic
bool NodeHelper::isNodeDisplayedEmbedded(KMime::Content *node) const
{
- qCDebug(MESSAGEVIEWER_LOG) << "IS NODE: " << mDisplayEmbeddedNodes.contains(node);
+ qCDebug(MIMETREEPARSER_LOG) << "IS NODE: " << mDisplayEmbeddedNodes.contains(node);
return mDisplayEmbeddedNodes.contains(node);
}
void NodeHelper::setNodeDisplayedEmbedded(KMime::Content *node, bool displayedEmbedded)
{
- qCDebug(MESSAGEVIEWER_LOG) << "SET NODE: " << node << displayedEmbedded;
+ qCDebug(MIMETREEPARSER_LOG) << "SET NODE: " << node << displayedEmbedded;
if (displayedEmbedded) {
mDisplayEmbeddedNodes.insert(node);
} else {
@@ -785,7 +785,7 @@ QString NodeHelper::fromAsString(KMime::Content *node)
void NodeHelper::attachExtraContent(KMime::Content *topLevelNode, KMime::Content *content)
{
- qCDebug(MESSAGEVIEWER_LOG) << "mExtraContents added for" << topLevelNode << " extra content: " << content;
+ qCDebug(MIMETREEPARSER_LOG) << "mExtraContents added for" << topLevelNode << " extra content: " << content;
mExtraContents[topLevelNode].append(content);
}
@@ -803,7 +803,7 @@ void NodeHelper::mergeExtraNodes(KMime::Content *node)
QList<KMime::Content * > extraNodes = extraContents(node);
Q_FOREACH (KMime::Content *extra, extraNodes) {
if (node->bodyIsMessage()) {
- qCWarning(MESSAGEVIEWER_LOG) << "Asked to attach extra content to a kmime::message, this does not make sense. Attaching to:" << node <<
+ qCWarning(MIMETREEPARSER_LOG) << "Asked to attach extra content to a kmime::message, this does not make sense. Attaching to:" << node <<
node->encodedContent() << "\n====== with =======\n" << extra << extra->encodedContent();
continue;
}
@@ -858,8 +858,8 @@ KMime::Message *NodeHelper::messageWithExtraContent(KMime::Content *topLevelNode
m->parse();
cleanFromExtraNodes(topLevelNode);
-// qCDebug(MESSAGEVIEWER_LOG) << "MESSAGE WITH EXTRA: " << m->encodedContent();
-// qCDebug(MESSAGEVIEWER_LOG) << "MESSAGE WITHOUT EXTRA: " << topLevelNode->encodedContent();
+// qCDebug(MIMETREEPARSER_LOG) << "MESSAGE WITH EXTRA: " << m->encodedContent();
+// qCDebug(MIMETREEPARSER_LOG) << "MESSAGE WITHOUT EXTRA: " << topLevelNode->encodedContent();
return m;
}
@@ -895,7 +895,7 @@ KMime::Content *NodeHelper::decryptedNodeForContent(KMime::Content *content) con
if (xc.size() == 1) {
return xc.front();
} else {
- qCWarning(MESSAGEVIEWER_LOG) << "WTF, encrypted node has multiple extra contents?";
+ qCWarning(MIMETREEPARSER_LOG) << "WTF, encrypted node has multiple extra contents?";
}
}
return 0;
@@ -913,7 +913,7 @@ bool NodeHelper::unencryptedMessage_helper(KMime::Content *node, QByteArray &res
const bool isMultipart = node->contentType(false) && node->contentType()->isMultipart();
bool isSignature = false;
- qCDebug(MESSAGEVIEWER_LOG) << "(" << recursionLevel << ") Looking at" << type << "/" << subType;
+ qCDebug(MIMETREEPARSER_LOG) << "(" << recursionLevel << ") Looking at" << type << "/" << subType;
if (isMultipart) {
if (subType == "signed") {
@@ -936,7 +936,7 @@ bool NodeHelper::unencryptedMessage_helper(KMime::Content *node, QByteArray &res
}
if (decryptedNode) {
- qCDebug(MESSAGEVIEWER_LOG) << "Current node has an associated decrypted node, adding a modified header "
+ qCDebug(MIMETREEPARSER_LOG) << "Current node has an associated decrypted node, adding a modified header "
"and then processing the children.";
Q_ASSERT(addHeaders);
@@ -972,7 +972,7 @@ bool NodeHelper::unencryptedMessage_helper(KMime::Content *node, QByteArray &res
}
else if (isSignature) {
- qCDebug(MESSAGEVIEWER_LOG) << "Current node is a signature, adding it as-is.";
+ qCDebug(MIMETREEPARSER_LOG) << "Current node is a signature, adding it as-is.";
// We can't change the nodes under the signature, as that would invalidate it. Add the signature
// and its child as-is
if (addHeaders) {
@@ -983,7 +983,7 @@ bool NodeHelper::unencryptedMessage_helper(KMime::Content *node, QByteArray &res
}
else if (isMultipart) {
- qCDebug(MESSAGEVIEWER_LOG) << "Current node is a multipart node, adding its header and then processing all children.";
+ qCDebug(MIMETREEPARSER_LOG) << "Current node is a multipart node, adding its header and then processing all children.";
// Normal multipart node, add the header and all of its children
bool somethingChanged = false;
if (addHeaders) {
@@ -1002,7 +1002,7 @@ bool NodeHelper::unencryptedMessage_helper(KMime::Content *node, QByteArray &res
}
else if (curNode->bodyIsMessage()) {
- qCDebug(MESSAGEVIEWER_LOG) << "Current node is a message, adding the header and then processing the child.";
+ qCDebug(MIMETREEPARSER_LOG) << "Current node is a message, adding the header and then processing the child.";
if (addHeaders) {
resultingData += curNode->head() + '\n';
}
@@ -1011,7 +1011,7 @@ bool NodeHelper::unencryptedMessage_helper(KMime::Content *node, QByteArray &res
}
else {
- qCDebug(MESSAGEVIEWER_LOG) << "Current node is an ordinary leaf node, adding it as-is.";
+ qCDebug(MIMETREEPARSER_LOG) << "Current node is an ordinary leaf node, adding it as-is.";
if (addHeaders) {
resultingData += curNode->head() + '\n';
}
@@ -1020,7 +1020,7 @@ bool NodeHelper::unencryptedMessage_helper(KMime::Content *node, QByteArray &res
}
}
- qCDebug(MESSAGEVIEWER_LOG) << "(" << recursionLevel << ") done.";
+ qCDebug(MIMETREEPARSER_LOG) << "(" << recursionLevel << ") done.";
return returnValue;
}
@@ -1030,7 +1030,7 @@ KMime::Message::Ptr NodeHelper::unencryptedMessage(const KMime::Message::Ptr &or
const bool messageChanged = unencryptedMessage_helper(originalMessage.data(), resultingData, true);
if (messageChanged) {
#if 0
- qCDebug(MESSAGEVIEWER_LOG) << "Resulting data is:" << resultingData;
+ qCDebug(MIMETREEPARSER_LOG) << "Resulting data is:" << resultingData;
QFile bla("stripped.mbox");
bla.open(QIODevice::WriteOnly);
bla.write(resultingData);
diff --git a/mimetreeparser/src/viewer/objecttreeparser.cpp b/mimetreeparser/src/viewer/objecttreeparser.cpp
index b6cbfd2..edcc0b0 100644
--- a/mimetreeparser/src/viewer/objecttreeparser.cpp
+++ b/mimetreeparser/src/viewer/objecttreeparser.cpp
@@ -54,7 +54,7 @@
#include "job/kleojobexecutor.h"
#include "nodehelper.h"
#include "utils/iconnamecache.h"
-#include "messageviewer_debug.h"
+#include "mimetreeparser_debug.h"
#include "converthtmltoplaintext.h"
// KDEPIM includes
@@ -242,16 +242,16 @@ bool ObjectTreeParser::printing() const
MimeMessagePart::Ptr ObjectTreeParser::createAndParseTempNode(KMime::Content *parentNode, const char *content, const char *cntDesc)
{
- // qCDebug(MESSAGEVIEWER_LOG) << "CONTENT: " << QByteArray( content ).left( 100 ) << " CNTDESC: " << cntDesc;
+ // qCDebug(MIMETREEPARSER_LOG) << "CONTENT: " << QByteArray( content ).left( 100 ) << " CNTDESC: " << cntDesc;
KMime::Content *newNode = new KMime::Content();
newNode->setContent(KMime::CRLFtoLF(content));
newNode->parse();
/*
- qCDebug(MESSAGEVIEWER_LOG) << "MEDIATYPE: " << newNode->contentType()->mediaType() << newNode->contentType()->mimeType() ;
- qCDebug(MESSAGEVIEWER_LOG) << "DECODEDCONTENT: " << newNode->decodedContent().left(400);
- qCDebug(MESSAGEVIEWER_LOG) << "ENCODEDCONTENT: " << newNode->encodedContent().left(400);
- qCDebug(MESSAGEVIEWER_LOG) << "BODY: " << newNode->body().left(400);
+ qCDebug(MIMETREEPARSER_LOG) << "MEDIATYPE: " << newNode->contentType()->mediaType() << newNode->contentType()->mimeType() ;
+ qCDebug(MIMETREEPARSER_LOG) << "DECODEDCONTENT: " << newNode->decodedContent().left(400);
+ qCDebug(MIMETREEPARSER_LOG) << "ENCODEDCONTENT: " << newNode->encodedContent().left(400);
+ qCDebug(MIMETREEPARSER_LOG) << "BODY: " << newNode->body().left(400);
*/
if (!newNode->head().isEmpty()) {
@@ -372,7 +372,7 @@ MessagePart::Ptr ObjectTreeParser::parseObjectTreeInternal(KMime::Content *node)
}
if (!bRendered) {
- qCCritical(MESSAGEVIEWER_LOG) << "THIS SHOULD NO LONGER HAPPEN:" << mediaType << '/' << subType;
+ qCCritical(MIMETREEPARSER_LOG) << "THIS SHOULD NO LONGER HAPPEN:" << mediaType << '/' << subType;
const auto mp = defaultHandling(node, processResult);
if (mp) {
mp->setAttachmentFlag(node);
@@ -397,7 +397,7 @@ MessagePart::Ptr ObjectTreeParser::defaultHandling(KMime::Content *node, Process
// ### (mmutz) default handling should go into the respective
// ### bodypartformatters.
if (!htmlWriter()) {
- qCWarning(MESSAGEVIEWER_LOG) << "no htmlWriter()";
+ qCWarning(MIMETREEPARSER_LOG) << "no htmlWriter()";
return MessagePart::Ptr();
}
@@ -657,10 +657,10 @@ bool ObjectTreeParser::okDecryptMIME(KMime::Content &data,
deb += QLatin1String("\"");
}
deb += "\n\n";
- qCDebug(MESSAGEVIEWER_LOG) << deb;
+ qCDebug(MIMETREEPARSER_LOG) << deb;
#endif
- qCDebug(MESSAGEVIEWER_LOG) << "going to call CRYPTPLUG" << cryptPlugLibName;
+ qCDebug(MIMETREEPARSER_LOG) << "going to call CRYPTPLUG" << cryptPlugLibName;
// Check whether the memento contains a result from last time:
const DecryptVerifyBodyPartMemento *m
@@ -702,7 +702,7 @@ bool ObjectTreeParser::okDecryptMIME(KMime::Content &data,
const GpgME::VerificationResult &verifyResult = m->verifyResult();
std::stringstream ss;
ss << decryptResult << '\n' << verifyResult;
- qCDebug(MESSAGEVIEWER_LOG) << ss.str().c_str();
+ qCDebug(MIMETREEPARSER_LOG) << ss.str().c_str();
signatureFound = verifyResult.signatures().size() > 0;
signatures = verifyResult.signatures();
bDecryptionOk = !decryptResult.error();
@@ -723,7 +723,7 @@ bool ObjectTreeParser::okDecryptMIME(KMime::Content &data,
partMetaData.keyId = decryptResult.recipient(0).keyID();
}
- qCDebug(MESSAGEVIEWER_LOG) << "ObjectTreeParser::decryptMIME: returned from CRYPTPLUG";
+ qCDebug(MIMETREEPARSER_LOG) << "ObjectTreeParser::decryptMIME: returned from CRYPTPLUG";
if (bDecryptionOk) {
decryptedData = plainText;
} else if (htmlWriter() && showWarning) {
@@ -878,7 +878,7 @@ MessagePart::Ptr ObjectTreeParser::processMailmanSubtype(KMime::Content *curNode
subject.truncate(thisEoL);
}
}
- qCDebug(MESSAGEVIEWER_LOG) << " embedded message found: \"" << subject;
+ qCDebug(MIMETREEPARSER_LOG) << " embedded message found: \"" << subject;
mpl->appendMessagePart(createAndParseTempNode(mTopLevelContent, partStr.toLatin1(), subject.toLatin1()));
//mReader->queueHtml("<br><hr><br>");
thisDelim = nextDelim + 1;
@@ -1019,7 +1019,7 @@ MessagePart::Ptr ObjectTreeParser::processMultiPartSignedSubtype(KMime::Content
KMime::Content *signedData = MessageCore::NodeHelper::firstChild(node);
assert(signedData);
if (node->contents().size() != 2) {
- qCDebug(MESSAGEVIEWER_LOG) << "mulitpart/signed must have exactly two child parts!" << endl
+ qCDebug(MIMETREEPARSER_LOG) << "mulitpart/signed must have exactly two child parts!" << endl
<< "processing as multipart/mixed";
return MessagePart::Ptr(new MimeMessagePart(this, signedData, false));
@@ -1031,7 +1031,7 @@ MessagePart::Ptr ObjectTreeParser::processMultiPartSignedSubtype(KMime::Content
QString protocolContentType = node->contentType()->parameter(QStringLiteral("protocol")).toLower();
const QString signatureContentType = QLatin1String(signature->contentType()->mimeType().toLower());
if (protocolContentType.isEmpty()) {
- qCWarning(MESSAGEVIEWER_LOG) << "Message doesn't set the protocol for the multipart/signed content-type, "
+ qCWarning(MIMETREEPARSER_LOG) << "Message doesn't set the protocol for the multipart/signed content-type, "
"using content-type of the signature:" << signatureContentType;
protocolContentType = signatureContentType;
}
@@ -1129,7 +1129,7 @@ MessagePart::Ptr ObjectTreeParser::processMultiPartEncryptedSubtype(KMime::Conte
} else {
mp->startDecryption(data);
- qCDebug(MESSAGEVIEWER_LOG) << "decrypted, signed?:" << messagePart->isSigned;
+ qCDebug(MIMETREEPARSER_LOG) << "decrypted, signed?:" << messagePart->isSigned;
if (!messagePart->inProgress) {
mNodeHelper->setNodeProcessed(data, false); // Set the data node to done to prevent it from being processed
@@ -1146,7 +1146,7 @@ MessagePart::Ptr ObjectTreeParser::processMultiPartEncryptedSubtype(KMime::Conte
// MUA 'should' have sent. :-D (khz, 12.09.2002)
mNodeHelper->setSignatureState(node, KMMsgFullySigned);
- qCDebug(MESSAGEVIEWER_LOG) << "setting FULLY SIGNED to:" << node;
+ qCDebug(MIMETREEPARSER_LOG) << "setting FULLY SIGNED to:" << node;
}
}
}
@@ -1189,9 +1189,9 @@ MessagePart::Ptr ObjectTreeParser::processApplicationPkcs7MimeSubtype(KMime::Con
CryptoMessagePart::Ptr mp;
if (!isSigned) {
if (isEncrypted) {
- qCDebug(MESSAGEVIEWER_LOG) << "pkcs7 mime == S/MIME TYPE: enveloped (encrypted) data";
+ qCDebug(MIMETREEPARSER_LOG) << "pkcs7 mime == S/MIME TYPE: enveloped (encrypted) data";
} else {
- qCDebug(MESSAGEVIEWER_LOG) << "pkcs7 mime - type unknown - enveloped (encrypted) data ?";
+ qCDebug(MIMETREEPARSER_LOG) << "pkcs7 mime - type unknown - enveloped (encrypted) data ?";
}
mp = CryptoMessagePart::Ptr(new CryptoMessagePart(this,
@@ -1206,7 +1206,7 @@ MessagePart::Ptr ObjectTreeParser::processApplicationPkcs7MimeSubtype(KMime::Con
} else {
mp->startDecryption();
if (messagePart->isDecryptable) {
- qCDebug(MESSAGEVIEWER_LOG) << "pkcs7 mime - encryption found - enveloped (encrypted) data !";
+ qCDebug(MIMETREEPARSER_LOG) << "pkcs7 mime - encryption found - enveloped (encrypted) data !";
isEncrypted = true;
mNodeHelper->setEncryptionState(node, KMMsgFullyEncrypted);
if (messagePart->isSigned) {
@@ -1225,9 +1225,9 @@ MessagePart::Ptr ObjectTreeParser::processApplicationPkcs7MimeSubtype(KMime::Con
}
if (isEncrypted) {
- qCDebug(MESSAGEVIEWER_LOG) << "pkcs7 mime - ERROR: COULD NOT DECRYPT enveloped data !";
+ qCDebug(MIMETREEPARSER_LOG) << "pkcs7 mime - ERROR: COULD NOT DECRYPT enveloped data !";
} else {
- qCDebug(MESSAGEVIEWER_LOG) << "pkcs7 mime - NO encryption found";
+ qCDebug(MIMETREEPARSER_LOG) << "pkcs7 mime - NO encryption found";
}
}
}
@@ -1240,9 +1240,9 @@ MessagePart::Ptr ObjectTreeParser::processApplicationPkcs7MimeSubtype(KMime::Con
// We now try signature verification if necessarry.
if (signTestNode) {
if (isSigned) {
- qCDebug(MESSAGEVIEWER_LOG) << "pkcs7 mime == S/MIME TYPE: opaque signed data";
+ qCDebug(MIMETREEPARSER_LOG) << "pkcs7 mime == S/MIME TYPE: opaque signed data";
} else {
- qCDebug(MESSAGEVIEWER_LOG) << "pkcs7 mime - type unknown - opaque signed data ?";
+ qCDebug(MIMETREEPARSER_LOG) << "pkcs7 mime - type unknown - opaque signed data ?";
}
const QTextCodec *aCodec(codecFor(signTestNode));
@@ -1260,7 +1260,7 @@ MessagePart::Ptr ObjectTreeParser::processApplicationPkcs7MimeSubtype(KMime::Con
if (messagePart->isSigned) {
if (!isSigned) {
- qCDebug(MESSAGEVIEWER_LOG) << "pkcs7 mime - signature found - opaque signed data !";
+ qCDebug(MIMETREEPARSER_LOG) << "pkcs7 mime - signature found - opaque signed data !";
isSigned = true;
}
@@ -1269,7 +1269,7 @@ MessagePart::Ptr ObjectTreeParser::processApplicationPkcs7MimeSubtype(KMime::Con
mNodeHelper->setSignatureState(node, KMMsgFullySigned);
}
} else {
- qCDebug(MESSAGEVIEWER_LOG) << "pkcs7 mime - NO signature found :-(";
+ qCDebug(MIMETREEPARSER_LOG) << "pkcs7 mime - NO signature found :-(";
}
}
@@ -1449,21 +1449,21 @@ void ObjectTreeParser::sigStatusToMetaData(const std::vector <GpgME::Signature>
// trust etc.
Kleo::KeyListJob *job = cryptProto->keyListJob(false); // local, no sigs
if (!job) {
- qCDebug(MESSAGEVIEWER_LOG) << "The Crypto backend does not support listing keys. ";
+ qCDebug(MIMETREEPARSER_LOG) << "The Crypto backend does not support listing keys. ";
} else {
std::vector<GpgME::Key> found_keys;
// As we are local it is ok to make this synchronous
GpgME::KeyListResult res = job->exec(QStringList(QLatin1String(signature.fingerprint())), false, found_keys);
if (res.error()) {
- qCDebug(MESSAGEVIEWER_LOG) << "Error while searching key for Fingerprint: " << signature.fingerprint();
+ qCDebug(MIMETREEPARSER_LOG) << "Error while searching key for Fingerprint: " << signature.fingerprint();
}
if (found_keys.size() > 1) {
// Should not Happen
- qCDebug(MESSAGEVIEWER_LOG) << "Oops: Found more then one Key for Fingerprint: " << signature.fingerprint();
+ qCDebug(MIMETREEPARSER_LOG) << "Oops: Found more then one Key for Fingerprint: " << signature.fingerprint();
}
if (found_keys.size() != 1) {
// Should not Happen at this point
- qCDebug(MESSAGEVIEWER_LOG) << "Oops: Found no Key for Fingerprint: " << signature.fingerprint();
+ qCDebug(MIMETREEPARSER_LOG) << "Oops: Found no Key for Fingerprint: " << signature.fingerprint();
} else {
key = found_keys[0];
}
@@ -1714,7 +1714,7 @@ QString ObjectTreeParser::quotedHTML(const QString &s, bool decorate)
htmlStr += quoteEnd + cssHelper()->addEndBlockQuote(currQuoteLevel + 1);
}
- // qCDebug(MESSAGEVIEWER_LOG) << "========================================\n"
+ // qCDebug(MIMETREEPARSER_LOG) << "========================================\n"
// << htmlStr
// << "\n======================================\n";
return htmlStr;
diff --git a/mimetreeparser/src/viewer/partnodebodypart.cpp b/mimetreeparser/src/viewer/partnodebodypart.cpp
index 50756e8..d0cb96a 100644
--- a/mimetreeparser/src/viewer/partnodebodypart.cpp
+++ b/mimetreeparser/src/viewer/partnodebodypart.cpp
@@ -34,7 +34,7 @@
#include "partnodebodypart.h"
#include "nodehelper.h"
#include "objecttreeparser.h"
-#include "messageviewer_debug.h"
+#include "mimetreeparser_debug.h"
#include <KMime/Content>
#include <QTextCodec>
@@ -90,7 +90,7 @@ QString PartNodeBodyPart::contentDispositionParameter(const char *param) const
bool PartNodeBodyPart::hasCompleteBody() const
{
- qCWarning(MESSAGEVIEWER_LOG) << "Sorry, not yet implemented.";
+ qCWarning(MIMETREEPARSER_LOG) << "Sorry, not yet implemented.";
return true;
}