summaryrefslogtreecommitdiff
path: root/lib/rexml/parsers/treeparser.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/rexml/parsers/treeparser.rb')
-rw-r--r--lib/rexml/parsers/treeparser.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/rexml/parsers/treeparser.rb b/lib/rexml/parsers/treeparser.rb
index a53fa41925..ff8261cedf 100644
--- a/lib/rexml/parsers/treeparser.rb
+++ b/lib/rexml/parsers/treeparser.rb
@@ -29,8 +29,7 @@ module REXML
return
when :start_element
tag_stack.push(event[1])
- # find the observers for namespaces
- @build_context = @build_context.add_element( event[1], event[2] )
+ el = @build_context = @build_context.add_element( event[1], event[2] )
when :end_element
tag_stack.pop
@build_context = @build_context.parent
@@ -86,6 +85,8 @@ module REXML
end
rescue REXML::Validation::ValidationException
raise
+ rescue REXML::UndefinedNamespaceException
+ raise
rescue
raise ParseException.new( $!.message, @parser.source, @parser, $! )
end