libxml-ruby 5.0.1 → 5.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 24e442a3a4f3343aaae6bc6b513309faccd90af0c9e985c6729d91821c9b29b4
4
- data.tar.gz: 698be20e816f96b896c3b8bd7cc0bcf89e131d8b46466e16b9d804133b8f5af2
3
+ metadata.gz: e036b762df752b8b3582af2d5b089f83bbb96b9791304159c7daa6dbe729a0b3
4
+ data.tar.gz: c14d980af288113cbafb50ee16448b335aa2936b351f8dbde786de4e84fdba78
5
5
  SHA512:
6
- metadata.gz: 4f90226185c4146bb9b0212d489e8913148408f09e315ebedbca43e44914534c595b89bd3238fa7bfabf9e21f1d3613e4b11980a82b8d4f844bbe07bd862b788
7
- data.tar.gz: 9313c21dc1405b5d0b015120e37a2310a7d337ff0948b2f2ed54c105e276b090c246314315c937f25444fa187c4fe101b618a8dec24b774deba85cb8e0ad414f
6
+ metadata.gz: f399b51f48b89992e39d822dcd37b2e703d475189a5ecae81ffa1b464c1f500c7318372d2f83a65bfc88c7ff9855a6af21d34366e05be5d6fe550485aea7d3a2
7
+ data.tar.gz: 2f97ce5a32ea77e54df431eb5ad7e7fcaa99d3aee704953956a6ec8d7fcfbe589abdad19949eb11b3c70f8f2b6f20b206944594d0fd3f14e90431d652d137c95
data/HISTORY CHANGED
@@ -1,5 +1,9 @@
1
1
  = Release History
2
2
 
3
+ == 5.0.2 / 2024-01-08
4
+
5
+ * Fix broken DTD creation (DTD name is not required)
6
+
3
7
  == 5.0.1 / 2024-01-08
4
8
 
5
9
  * Fix broken Document#io method that was broken by switching Parsers to use keyword arguments
@@ -132,8 +132,8 @@ static VALUE rxml_dtd_type(VALUE self)
132
132
  *
133
133
  * * The first usage creates a DTD from a string and requires 1 parameter.
134
134
  * * The second usage loads and parses an external DTD and requires 2 parameters.
135
- * * The third usage creates a new internal or external DTD and requires 3 parameters and 2 optional parameters.
136
- * It then attaches the DTD to the specified document if it is not nil
135
+ * * The third usage creates a new internal or external DTD and requires 2 parameters and 3 optional parameters.
136
+ * The DTD is then attached to the specified document if it is not nil.
137
137
  *
138
138
  * Parameters:
139
139
  *
@@ -160,7 +160,7 @@ static VALUE rxml_dtd_initialize(int argc, VALUE *argv, VALUE self)
160
160
  xmlDocPtr xdoc = NULL;
161
161
 
162
162
  VALUE name, doc, internal;
163
- rb_scan_args(argc, argv, "32", &external, &system, &name, &doc, &internal);
163
+ rb_scan_args(argc, argv, "23", &external, &system, &name, &doc, &internal);
164
164
 
165
165
  Check_Type(external, T_STRING);
166
166
  xpublic = (const xmlChar*) StringValuePtr(external);
@@ -168,8 +168,11 @@ static VALUE rxml_dtd_initialize(int argc, VALUE *argv, VALUE self)
168
168
  Check_Type(system, T_STRING);
169
169
  xsystem = (const xmlChar*) StringValuePtr(system);
170
170
 
171
- Check_Type(name, T_STRING);
172
- xname = (const xmlChar*) StringValuePtr(name);
171
+ if (name != Qnil)
172
+ {
173
+ Check_Type(name, T_STRING);
174
+ xname = (const xmlChar*)StringValuePtr(name);
175
+ }
173
176
 
174
177
  if (doc != Qnil)
175
178
  {
@@ -1,9 +1,9 @@
1
1
  /* Don't nuke this block! It is used for automatically updating the
2
2
  * versions below. VERSION = string formatting, VERNUM = numbered
3
3
  * version for inline testing: increment both or none at all.*/
4
- #define RUBY_LIBXML_VERSION "5.0.1"
5
- #define RUBY_LIBXML_VERNUM 501
4
+ #define RUBY_LIBXML_VERSION "5.0.2"
5
+ #define RUBY_LIBXML_VERNUM 502
6
6
  #define RUBY_LIBXML_VER_MAJ 5
7
7
  #define RUBY_LIBXML_VER_MIN 0
8
- #define RUBY_LIBXML_VER_MIC 1
8
+ #define RUBY_LIBXML_VER_MIC 2
9
9
  #define RUBY_LIBXML_VER_PATCH 0
@@ -82,7 +82,7 @@ class TestDocument < Minitest::Test
82
82
  def test_xhtml
83
83
  doc = LibXML::XML::Document.new
84
84
  assert(!doc.xhtml?)
85
- LibXML::XML::Dtd.new "-//W3C//DTD XHTML 1.0 Transitional//EN", "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd", nil, doc, true
85
+ LibXML::XML::Dtd.new("-//W3C//DTD XHTML 1.0 Transitional//EN", "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd", nil, doc, true)
86
86
  assert(doc.xhtml?)
87
87
  end
88
88
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: libxml-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.0.1
4
+ version: 5.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ross Bamform
@@ -275,7 +275,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
275
275
  - !ruby/object:Gem::Version
276
276
  version: '0'
277
277
  requirements: []
278
- rubygems_version: 3.4.21
278
+ rubygems_version: 3.5.3
279
279
  signing_key:
280
280
  specification_version: 4
281
281
  summary: Ruby Bindings for LibXML2