summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swiften/Serializer')
-rw-r--r--Swiften/Serializer/PayloadSerializers/SecurityLabelSerializer.cpp12
-rw-r--r--Swiften/Serializer/PayloadSerializers/UnitTest/SecurityLabelSerializerTest.cpp10
-rw-r--r--Swiften/Serializer/PayloadSerializers/UnitTest/SecurityLabelsCatalogSerializerTest.cpp2
-rw-r--r--Swiften/Serializer/PayloadSerializers/UnitTest/VCardUpdateSerializerTest.cpp6
-rw-r--r--Swiften/Serializer/XML/XMLElement.cpp2
5 files changed, 16 insertions, 16 deletions
diff --git a/Swiften/Serializer/PayloadSerializers/SecurityLabelSerializer.cpp b/Swiften/Serializer/PayloadSerializers/SecurityLabelSerializer.cpp
index e53c6b7..f155f22 100644
--- a/Swiften/Serializer/PayloadSerializers/SecurityLabelSerializer.cpp
+++ b/Swiften/Serializer/PayloadSerializers/SecurityLabelSerializer.cpp
@@ -13,12 +13,12 @@ String SecurityLabelSerializer::serializePayload(boost::shared_ptr<SecurityLabel
XMLElement element("securitylabel", "urn:xmpp:sec-label:0");
if (!label->getDisplayMarking().isEmpty()) {
boost::shared_ptr<XMLElement> displayMarking(new XMLElement("displaymarking"));
- if (!label->getForegroundColor().isEmpty()) {
- displayMarking->setAttribute("fgcolor", label->getForegroundColor());
- }
- if (!label->getBackgroundColor().isEmpty()) {
- displayMarking->setAttribute("bgcolor", label->getBackgroundColor());
- }
+ if (!label->getForegroundColor().isEmpty()) {
+ displayMarking->setAttribute("fgcolor", label->getForegroundColor());
+ }
+ if (!label->getBackgroundColor().isEmpty()) {
+ displayMarking->setAttribute("bgcolor", label->getBackgroundColor());
+ }
displayMarking->addNode(boost::shared_ptr<XMLTextNode>(new XMLTextNode(label->getDisplayMarking())));
element.addNode(displayMarking);
}
diff --git a/Swiften/Serializer/PayloadSerializers/UnitTest/SecurityLabelSerializerTest.cpp b/Swiften/Serializer/PayloadSerializers/UnitTest/SecurityLabelSerializerTest.cpp
index e8b89ad..c95ae10 100644
--- a/Swiften/Serializer/PayloadSerializers/UnitTest/SecurityLabelSerializerTest.cpp
+++ b/Swiften/Serializer/PayloadSerializers/UnitTest/SecurityLabelSerializerTest.cpp
@@ -26,17 +26,17 @@ class SecurityLabelSerializerTest : public CppUnit::TestFixture
CPPUNIT_ASSERT_EQUAL(String(
"<securitylabel xmlns=\"urn:xmpp:sec-label:0\">"
- "<displaymarking bgcolor=\"red\" fgcolor=\"black\">SECRET</displaymarking>"
- "<label>"
+ "<displaymarking bgcolor=\"red\" fgcolor=\"black\">SECRET</displaymarking>"
+ "<label>"
"<esssecuritylabel xmlns=\"urn:xmpp:sec-label:ess:0\">MQYCAQQGASk=</esssecuritylabel>"
"</label>"
- "<equivalentlabel>"
+ "<equivalentlabel>"
"<icismlabel xmlns=\"http://example.gov/IC-ISM/0\" classification=\"S\" ownerProducer=\"USA\" disseminationControls=\"FOUO\"/>"
"</equivalentlabel>"
- "<equivalentlabel>"
+ "<equivalentlabel>"
"<esssecuritylabel xmlns=\"urn:xmpp:sec-label:ess:0\">MRUCAgD9DA9BcXVhIChvYnNvbGV0ZSk=</esssecuritylabel>"
"</equivalentlabel>"
- "</securitylabel>"), testling.serialize(securityLabel));
+ "</securitylabel>"), testling.serialize(securityLabel));
}
};
diff --git a/Swiften/Serializer/PayloadSerializers/UnitTest/SecurityLabelsCatalogSerializerTest.cpp b/Swiften/Serializer/PayloadSerializers/UnitTest/SecurityLabelsCatalogSerializerTest.cpp
index acea1e4..3055aca 100644
--- a/Swiften/Serializer/PayloadSerializers/UnitTest/SecurityLabelsCatalogSerializerTest.cpp
+++ b/Swiften/Serializer/PayloadSerializers/UnitTest/SecurityLabelsCatalogSerializerTest.cpp
@@ -45,7 +45,7 @@ class SecurityLabelsCatalogSerializerTest : public CppUnit::TestFixture
"<displaymarking bgcolor=\"navy\" fgcolor=\"black\">CONFIDENTIAL</displaymarking>"
"<label><esssecuritylabel xmlns=\"urn:xmpp:sec-label:ess:0\">MQMGASk=</esssecuritylabel></label>"
"</securitylabel>"
- "</catalog>"), testling.serialize(catalog));
+ "</catalog>"), testling.serialize(catalog));
}
};
diff --git a/Swiften/Serializer/PayloadSerializers/UnitTest/VCardUpdateSerializerTest.cpp b/Swiften/Serializer/PayloadSerializers/UnitTest/VCardUpdateSerializerTest.cpp
index fc7e442..23988d7 100644
--- a/Swiften/Serializer/PayloadSerializers/UnitTest/VCardUpdateSerializerTest.cpp
+++ b/Swiften/Serializer/PayloadSerializers/UnitTest/VCardUpdateSerializerTest.cpp
@@ -20,9 +20,9 @@ class VCardUpdateSerializerTest : public CppUnit::TestFixture
update->setPhotoHash("sha1-hash-of-image");
String expectedResult =
- "<x xmlns=\"vcard-temp:x:update\">"
- "<photo>sha1-hash-of-image</photo>"
- "</x>";
+ "<x xmlns=\"vcard-temp:x:update\">"
+ "<photo>sha1-hash-of-image</photo>"
+ "</x>";
CPPUNIT_ASSERT_EQUAL(expectedResult, testling.serialize(update));
}
diff --git a/Swiften/Serializer/XML/XMLElement.cpp b/Swiften/Serializer/XML/XMLElement.cpp
index af2cb34..71f4d0c 100644
--- a/Swiften/Serializer/XML/XMLElement.cpp
+++ b/Swiften/Serializer/XML/XMLElement.cpp
@@ -16,7 +16,7 @@ String XMLElement::serialize() {
result += "<" + tag_;
typedef std::pair<String,String> Pair;
foreach(const Pair& p, attributes_) {
- result += " " + p.first + "=\"" + p.second + "\"";
+ result += " " + p.first + "=\"" + p.second + "\"";
}
if (childNodes_.size() > 0) {