From 933c092395b6cee05e3e5bbf9fa67ff718ac6893 Mon Sep 17 00:00:00 2001
From: "arseny.kapoulkine"
 <arseny.kapoulkine@99668b35-9821-0410-8761-19e4c4f06640>
Date: Tue, 2 Feb 2010 19:59:06 +0000
Subject: [PATCH] XPath: xpath_ast_node ctors now initialize all members (code
 analysis warnings fix)

git-svn-id: http://pugixml.googlecode.com/svn/trunk@242 99668b35-9821-0410-8761-19e4c4f06640
---
 src/pugixpath.cpp | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)

diff --git a/src/pugixpath.cpp b/src/pugixpath.cpp
index b7efa46c..288f5584 100644
--- a/src/pugixpath.cpp
+++ b/src/pugixpath.cpp
@@ -1910,25 +1910,27 @@ namespace pugi
 		}
 	public:
 		xpath_ast_node(ast_type_t type, const char* contents, xpath_allocator& a): m_type(type),
-			m_rettype(xpath_type_none), m_left(0), m_right(0), m_third(0), m_next(0), m_contents(0)
+			m_rettype(xpath_type_none), m_left(0), m_right(0), m_third(0), m_next(0), m_contents(0),
+			m_axis(axis_self), m_test(nodetest_none)
 		{
 			set_contents(contents, a);
 		}
 		
 		xpath_ast_node(ast_type_t type, xpath_ast_node* left, xpath_ast_node* right, axis_t axis): m_type(type),
 			m_rettype(xpath_type_none), m_left(left), m_right(right), m_third(0), m_next(0), m_contents(0),
-			m_axis(axis)
+			m_axis(axis), m_test(nodetest_none)
 		{
 		}
 
 		xpath_ast_node(ast_type_t type, xpath_ast_node* left = 0, xpath_ast_node* right = 0, xpath_ast_node* third = 0): m_type(type),
-			m_rettype(xpath_type_none), m_left(left), m_right(right), m_third(third), m_next(0), m_contents(0)
+			m_rettype(xpath_type_none), m_left(left), m_right(right), m_third(third), m_next(0), m_contents(0),
+			m_axis(axis_self), m_test(nodetest_none)
 		{
 		}
 
 		xpath_ast_node(ast_type_t type, xpath_ast_node* left, axis_t axis, nodetest_t test, const char* contents, xpath_allocator& a):
-			m_type(type), m_rettype(xpath_type_none), m_left(left), m_right(0), m_third(0), m_next(0),
-			m_contents(0), m_axis(axis), m_test(test)
+			m_type(type), m_rettype(xpath_type_none), m_left(left), m_right(0), m_third(0), m_next(0), m_contents(0),
+			m_axis(axis), m_test(test)
 		{
 			set_contents(contents, a);
 		}
-- 
GitLab