From 7d03474e499e9d357c2d69e2333ba5dd0dc03fd4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Remko=20Tron=C3=A7on?= <git@el-tramo.be>
Date: Fri, 31 Jul 2009 18:34:49 +0200
Subject: ExpatParser: Fix invalid handleEndElement()


diff --git a/Swiften/Parser/ExpatParser.cpp b/Swiften/Parser/ExpatParser.cpp
index 6d23c93..6f7ff86 100644
--- a/Swiften/Parser/ExpatParser.cpp
+++ b/Swiften/Parser/ExpatParser.cpp
@@ -32,6 +32,10 @@ static void handleStartElement(void* client, const XML_Char* name, const XML_Cha
 
 static void handleEndElement(void* client, const XML_Char* name) {
 	std::pair<String,String> nsTagPair = String(name).getSplittedAtFirst(NAMESPACE_SEPARATOR);
+	if (nsTagPair.second == "") {
+		nsTagPair.second = nsTagPair.first;
+		nsTagPair.first = "";
+	}
 	static_cast<XMLParserClient*>(client)->handleEndElement(nsTagPair.second, nsTagPair.first);
 }
 
-- 
cgit v0.10.2-6-g49f6