summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swiften/Serializer')
-rw-r--r--Swiften/Serializer/PayloadSerializers/FormSerializer.cpp1
-rw-r--r--Swiften/Serializer/PayloadSerializers/WhiteboardSerializer.cpp4
-rw-r--r--Swiften/Serializer/StanzaSerializer.cpp4
-rw-r--r--Swiften/Serializer/XMPPSerializer.cpp4
4 files changed, 6 insertions, 7 deletions
diff --git a/Swiften/Serializer/PayloadSerializers/FormSerializer.cpp b/Swiften/Serializer/PayloadSerializers/FormSerializer.cpp
index 9a05431..ed010b4 100644
--- a/Swiften/Serializer/PayloadSerializers/FormSerializer.cpp
+++ b/Swiften/Serializer/PayloadSerializers/FormSerializer.cpp
@@ -6,7 +6,6 @@
#include <Swiften/Serializer/PayloadSerializers/FormSerializer.h>
-#include <iostream>
#include <memory>
#include <string>
diff --git a/Swiften/Serializer/PayloadSerializers/WhiteboardSerializer.cpp b/Swiften/Serializer/PayloadSerializers/WhiteboardSerializer.cpp
index 5aebca3..34fd149 100644
--- a/Swiften/Serializer/PayloadSerializers/WhiteboardSerializer.cpp
+++ b/Swiften/Serializer/PayloadSerializers/WhiteboardSerializer.cpp
@@ -12,11 +12,11 @@
#include <Swiften/Serializer/PayloadSerializers/WhiteboardSerializer.h>
-#include <iostream>
#include <memory>
#include <boost/lexical_cast.hpp>
+#include <Swiften/Base/Log.h>
#include <Swiften/Elements/Whiteboard/WhiteboardDeleteOperation.h>
#include <Swiften/Elements/Whiteboard/WhiteboardInsertOperation.h>
#include <Swiften/Elements/Whiteboard/WhiteboardUpdateOperation.h>
@@ -199,7 +199,7 @@ namespace Swift {
case WhiteboardPayload::SessionTerminate:
return "session-terminate";
case WhiteboardPayload::UnknownType:
- std::cerr << "Warning: Serializing unknown action value." << std::endl;
+ SWIFT_LOG(warning) << "Serializing unknown action value." << std::endl;
return "";
}
assert(false);
diff --git a/Swiften/Serializer/StanzaSerializer.cpp b/Swiften/Serializer/StanzaSerializer.cpp
index de1e8f1..6440fbb 100644
--- a/Swiften/Serializer/StanzaSerializer.cpp
+++ b/Swiften/Serializer/StanzaSerializer.cpp
@@ -6,10 +6,10 @@
#include <Swiften/Serializer/StanzaSerializer.h>
-#include <iostream>
#include <sstream>
#include <typeinfo>
+#include <Swiften/Base/Log.h>
#include <Swiften/Base/foreach.h>
#include <Swiften/Elements/Stanza.h>
#include <Swiften/Serializer/PayloadSerializer.h>
@@ -53,7 +53,7 @@ SafeByteArray StanzaSerializer::serialize(std::shared_ptr<ToplevelElement> eleme
serializedPayloads += serializer->serialize(payload);
}
else {
- std::cerr << "Could not find serializer for " << typeid(*(payload.get())).name() << std::endl;
+ SWIFT_LOG(warning) << "Could not find serializer for " << typeid(*(payload.get())).name() << std::endl;
}
}
if (!serializedPayloads.empty()) {
diff --git a/Swiften/Serializer/XMPPSerializer.cpp b/Swiften/Serializer/XMPPSerializer.cpp
index 8b2fd5c..08b5485 100644
--- a/Swiften/Serializer/XMPPSerializer.cpp
+++ b/Swiften/Serializer/XMPPSerializer.cpp
@@ -7,11 +7,11 @@
#include <Swiften/Serializer/XMPPSerializer.h>
#include <cassert>
-#include <iostream>
#include <memory>
#include <boost/bind.hpp>
+#include <Swiften/Base/Log.h>
#include <Swiften/Base/foreach.h>
#include <Swiften/Elements/ProtocolHeader.h>
#include <Swiften/Serializer/AuthChallengeSerializer.h>
@@ -90,7 +90,7 @@ SafeByteArray XMPPSerializer::serializeElement(std::shared_ptr<ToplevelElement>
return (*i)->serialize(element);
}
else {
- std::cerr << "Could not find serializer for " << typeid(*(element.get())).name() << std::endl;
+ SWIFT_LOG(warning) << "Could not find serializer for " << typeid(*(element.get())).name() << std::endl;
return createSafeByteArray("");
}
}