leptris 1.9.237.0-x86_64-linux → 1.9.237.1-x86_64-linux
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/ext/leptris/native/native.c +11 -6
- data/lib/leptris/version.rb +1 -1
- data/lib/leptris/xml/native.so +0 -0
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 118128b008964bad00dec9ed6155f592be06749498e8cab6d0d5151f074d2c9a
|
|
4
|
+
data.tar.gz: 9040e71e461310ead4b130164c297133cba797670f578c7cc2f39c73f9cfd62b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 9bda865e3011cb4b83e2858412712e206a9d55a5f5321b7f8964e4f65ab976fbb4e95bf51ae2f47ea67959a4921b06eae79bd9e325557edc5789bb03db224a60
|
|
7
|
+
data.tar.gz: f4db1b897aea5c6d6ffcf172716d84b280bab2127c780eedca9e953ec2e3f2f8247786d348d828f161c53346a4d2b011ea66471084badf5606d9c953243244ec
|
data/ext/leptris/native/native.c
CHANGED
|
@@ -2294,14 +2294,15 @@ static VALUE nf_create_element_with_attrs(VALUE self, VALUE document,
|
|
|
2294
2294
|
VALUE parent_addr, VALUE name,
|
|
2295
2295
|
VALUE attrs)
|
|
2296
2296
|
{
|
|
2297
|
-
(
|
|
2298
|
-
|
|
2297
|
+
void *doc_ptr = NIL_P(document)
|
|
2298
|
+
? NULL
|
|
2299
|
+
: (void *)(uintptr_t)NUM2ULL(document);
|
|
2299
2300
|
void *parent = NIL_P(parent_addr)
|
|
2300
2301
|
? NULL
|
|
2301
2302
|
: (void *)(uintptr_t)NUM2ULL(parent_addr);
|
|
2302
2303
|
const char *cname = StringValueCStr(name);
|
|
2303
2304
|
|
|
2304
|
-
if (f_elem_new_with_attrs && parent && RARRAY_LEN(attrs) > 0 &&
|
|
2305
|
+
if (f_elem_new_with_attrs && doc_ptr && parent && RARRAY_LEN(attrs) > 0 &&
|
|
2305
2306
|
RARRAY_LEN(attrs) % 2 == 0) {
|
|
2306
2307
|
/* Engine single-crossing construction (1.9.236+): arena
|
|
2307
2308
|
* create + all attributes with no per-attr calls at all. */
|
|
@@ -2316,9 +2317,13 @@ static VALUE nf_create_element_with_attrs(VALUE self, VALUE document,
|
|
|
2316
2317
|
names[i] = StringValueCStr(an);
|
|
2317
2318
|
values[i] = StringValueCStr(av);
|
|
2318
2319
|
}
|
|
2319
|
-
void *elem = f_elem_new_with_attrs(
|
|
2320
|
-
n);
|
|
2321
|
-
|
|
2320
|
+
void *elem = f_elem_new_with_attrs(doc_ptr, cname, names,
|
|
2321
|
+
values, n);
|
|
2322
|
+
if (!elem) return Qnil;
|
|
2323
|
+
/* The face creates a floating element owned by the
|
|
2324
|
+
* document — append under the parent afterwards. */
|
|
2325
|
+
if (parent) f_append_child(parent, elem);
|
|
2326
|
+
return ULL2NUM((uintptr_t)elem);
|
|
2322
2327
|
}
|
|
2323
2328
|
|
|
2324
2329
|
void *elem = parent ? f_create_child(parent, cname) : NULL;
|
data/lib/leptris/version.rb
CHANGED
data/lib/leptris/xml/native.so
CHANGED
|
Binary file
|