[gnote] Properly handle empty xml elements when reading note
- From: Aurimas Černius <aurimasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnote] Properly handle empty xml elements when reading note
- Date: Sat, 5 Nov 2016 19:34:41 +0000 (UTC)
commit 554f77792693ab69f074948da9907880b2b7ba74
Author: Aurimas Černius <aurisc4 gmail com>
Date: Sat Nov 5 21:33:35 2016 +0200
Properly handle empty xml elements when reading note
Fixes Bug 773630.
src/notebuffer.cpp | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/src/notebuffer.cpp b/src/notebuffer.cpp
index 107fdb3..b19cb30 100644
--- a/src/notebuffer.cpp
+++ b/src/notebuffer.cpp
@@ -1542,7 +1542,9 @@ namespace gnote {
NoteTag::Ptr::cast_dynamic(tag_start.tag)->read (xml, true);
}
- tag_stack.push (tag_start);
+ if(!xml.is_empty_element()) {
+ tag_stack.push (tag_start);
+ }
break;
case XML_READER_TYPE_TEXT:
case XML_READER_TYPE_WHITESPACE:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]