Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 202426

Summary: dev-lang/ruby-1.8.6_p110-r1 and REXML::Document.write
Product: Gentoo Linux Reporter: Denis Misiurca <infoman1985>
Component: [OLD] DevelopmentAssignee: Gentoo Ruby Team <ruby>
Status: RESOLVED DUPLICATE    
Severity: normal    
Priority: High    
Version: 2007.0   
Hardware: All   
OS: Linux   
URL: http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/tags/v1_8_6_110/lib/rexml/document.rb?r1=11752&r2=12852
Whiteboard:
Package list:
Runtime testing required: ---

Description Denis Misiurca 2007-12-15 21:56:33 UTC
Tried to write a simple test program in Ruby, but got an error. I discovered that there are improper variable names in write method:
  def write( output=$stdout, indent=-1, trans=false, ie_hack=false )

but inside method:
  if transitive

Reproducible: Always

Steps to Reproduce:
1. doc = REXML::Document.new(somexml)
   doc.write($stdout, 4, true)
2. see the error message.
Actual Results:  
/usr/lib/ruby/1.8/rexml/document.rb:186:in `write': undefined local variable or method `transitive' for <UNDEFINED> ... </>:REXML::Document (NameError)
        from ./textxml.rb:14

Expected Results:  
As described in http://ruby-doc.org/stdlib/libdoc/rexml/rdoc/classes/REXML/Document.html#M002925
Comment 2 Denis Misiurca 2007-12-15 22:28:22 UTC
See http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/trunk/lib/rexml/document.rb?r1=13597&r2=13686 for how to fix this.
Comment 3 Hans de Graaff gentoo-dev Security 2007-12-17 19:54:46 UTC

*** This bug has been marked as a duplicate of bug 195505 ***