summaryrefslogtreecommitdiffstats
path: root/lib/rss/parser.rb
diff options
context:
space:
mode:
authorkou <kou@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2005-02-14 15:01:05 +0000
committerkou <kou@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2005-02-14 15:01:05 +0000
commit70a05a3e82c9e47757caf8d2873cf3bc80ec22d9 (patch)
tree3fd5dc0c3e5b9cf8afca92c34ad2af3813b3d95f /lib/rss/parser.rb
parent05529af1aceb492ab9e5b676e40e275ab48a7f2f (diff)
downloadruby-70a05a3e82c9e47757caf8d2873cf3bc80ec22d9.tar.gz
ruby-70a05a3e82c9e47757caf8d2873cf3bc80ec22d9.tar.xz
ruby-70a05a3e82c9e47757caf8d2873cf3bc80ec22d9.zip
* lib/rss/parser.rb (RSS::ListenerMixin::tag_end):
fixed invalid namespace handling bug. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@7971 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/rss/parser.rb')
-rw-r--r--lib/rss/parser.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/rss/parser.rb b/lib/rss/parser.rb
index 1030c8f5d..fb6c55fb7 100644
--- a/lib/rss/parser.rb
+++ b/lib/rss/parser.rb
@@ -229,7 +229,7 @@ module RSS
ns = @ns_stack.last.dup
attrs = {}
attributes.each do |n, v|
- if n =~ /\Axmlns:?/
+ if /\Axmlns(?:\z|:)/ =~ n
ns[$POSTMATCH] = v
else
attrs[n] = v
@@ -256,6 +256,7 @@ module RSS
tags = @tag_stack.pop
pr = @proc_stack.pop
pr.call(text, tags) unless pr.nil?
+ @ns_stack.pop
end
def text(data)