Permalink
Browse files

Updated version to 2.0.3.

  • Loading branch information...
1 parent 1ac5590 commit 5f475e6d55a443529e2f186d6c0ec63193d9839a @cfis committed May 1, 2011
Showing with 81 additions and 5 deletions.
  1. +49 −1 HISTORY
  2. +28 −0 README.rdoc
  3. +3 −3 ext/libxml/ruby_xml_version.h
  4. +1 −1 ext/vc/libxml_ruby_19/libxml_ruby_19.vcxproj
View
50 HISTORY
@@ -1,6 +1,54 @@
= Release History
-== 2.0.1 / 2011-04-17 Charlie Savage
+== 2.0.3 / 2011-05-01 Charlie Savage
+
+* The biggest change in this release is supporting the use of libxml-ruby in
+ native background Ruby threads. Previously, the use of libxml-ruby in
+ background threads in Ruby 1.9.x and higher would often cause
+ segmentation faults. This has now been fixed (Charlie Savage).
+
+* Add check to verify a node has not been deleted. This can happen when
+ a ruby variable holds a reference to a child node that gets freed
+ when its parent gets freed. Previously when this happened a
+ segmentation fault would occur, now an exception is raised (Charlie Savage, fixes
+ RubyForge #26839.
+
+* Do not unlink nodes before internal validations have run - avoids
+ segmentation faults caused by freeing a node twice (Charlie Savage).
+
+* Add support for Document#canonicalization (Victor Lin).
+
+* Fix memory leak in Reader#lookup_namespace (Charlie Savage).
+
+* Fix memory leak in Reader#[] (Nathan Kriege).
+
+* Fix usage of @io instance variable (Jeffrey Taylor)
+
+* Removed old sax error handling code that has been fixed in newer
+ versions of libxml (Charlie Savage).
+
+* Code cleanup - remove unused variables and commented out code (Charlie Savage)
+
+* Minor text changes and documentation fixes (Charlie Savage).
+
+* Fix documentation error (fixes RubyForge #26888).
+
+* Update documentation for Document#validation* methods (fixes RubyForge #24833).
+
+* Update documentation and test (fixes Ruby Forge Issue #28770).
+
+* Updated documentation in README (Anurag Priyam):
+1. rake doc does not work; use rake rdoc.
+2. gem mislav-hanna does not exist; use hanna.
+3. rake rdoc 'depends' on hanna; no need of RDOCOPTS
+4. Point to the github issue tracker instead of Ruby Forge
+5. Point to the github (gh-pages) site for docs
+
+* Add tc_error to test suite (Charlie Savage).
+
+* Add sax test (Stanislav O.Pogrebnyak).
+
+== 2.0.2 / 2011-04-17 Charlie Savage
* Added binaries for windows (Charlie Savage).
View
@@ -111,6 +111,34 @@ For example:
For simplicity's sake, the documentation uses the xml module in its examples.
+== Memory Management
+libxml-ruby automatically manages memory associated with the
+underlying libxml2 library. There is however one corner case that
+your code must handle. If a node is imported into a document, but not
+added to the document, a segmentation fault may occur on program termination.
+
+ # Do NOT do this
+ require 'xml'
+ doc1 = XML::Document.string("test1")
+ doc2 = XML::Document.string("test2")
+ node = doc2.import(doc1.root)
+
+If doc2 is freed before node2 a segmentatin fault will occur since
+node2 references the document. To avoid this, simply make sure to add the
+node to the document:
+
+ # DO this instead
+ doc1 = XML::Document.string("test1")
+ doc2 = XML::Document.string("test2")
+ doc2.root << doc2.import(doc1.root)
+
+Alternatively, you can call node2.remove! to disassociate node2 from doc2.
+
+== Threading
+libxml-ruby fully supports native, background Ruby threads. This of course
+only applies to Ruby 1.9.x and higher since earlier versions of Ruby do not
+support native threads.
+
== Performance
In addition to being feature rich and conformation, the main reason
people use libxml-ruby is for performance. Here are the results
@@ -1,9 +1,9 @@
/* Don't nuke this block! It is used for automatically updating the
* versions below. VERSION = string formatting, VERNUM = numbered
* version for inline testing: increment both or none at all.*/
-#define RUBY_LIBXML_VERSION "2.0.2"
-#define RUBY_LIBXML_VERNUM 202
+#define RUBY_LIBXML_VERSION "2.0.3"
+#define RUBY_LIBXML_VERNUM 203
#define RUBY_LIBXML_VER_MAJ 2
#define RUBY_LIBXML_VER_MIN 0
-#define RUBY_LIBXML_VER_MIC 2
+#define RUBY_LIBXML_VER_MIC 3
#define RUBY_LIBXML_VER_PATCH 0
@@ -37,7 +37,7 @@
<PropertyGroup Label="UserMacros" />
<PropertyGroup>
<_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion>
- <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">C:\MinGW\local\src\libxml-ruby\lib\1.9</OutDir>
+ <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">C:\MinGW\local\src\libxml-ruby\lib\1.9\</OutDir>
<IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(Configuration)\</IntDir>
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</LinkIncremental>
<OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)$(Configuration)\</OutDir>

0 comments on commit 5f475e6

Please sign in to comment.