ruby-oci8 2.2.12 → 2.2.13
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/NEWS +18 -0
- data/docs/hanging-after-inactivity.md +1 -1
- data/ext/oci8/extconf.rb +1 -0
- data/ext/oci8/oci8.c +2 -2
- data/ext/oci8/oci8.h +6 -5
- data/ext/oci8/oci8lib.c +0 -21
- data/ext/oci8/oraconf.rb +4 -0
- data/ext/oci8/oradate.c +0 -11
- data/ext/oci8/plthook_elf.c +312 -183
- data/ext/oci8/plthook_osx.c +649 -91
- data/ext/oci8/plthook_win32.c +39 -25
- data/lib/oci8/oracle_version.rb +9 -1
- data/lib/oci8/version.rb +1 -1
- data/lib/oci8.rb +2 -0
- data/test/test_metadata.rb +1 -0
- data/test/test_oranumber.rb +3 -1
- data/test/test_package_type.rb +10 -4
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1db88cf1bfe7291cc597bd695db32ea0e730734650c3bdfd40b9295663d0ac5e
|
4
|
+
data.tar.gz: 96f6b1b9fff2ba6067421d588495298cb14b5d42aa1fe7d4257c18431fdca654
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: da88c45ce3e73abb6cf30ad9633286204c3869a7b5e5f8e5acaeb90a824f7bb91d842c7da807e4639ff6993cf6d2bae96f9f5fe8cd64144f836eeca61c7fc85f
|
7
|
+
data.tar.gz: '088b13f4df8245aa95abdb2e2bf744c2088fa3fe87ffd5ffcdfedf0b43a724630d9a3603468269e6bf5790c4480d4e85a79a28af4db18bd05310b39c7dafed74'
|
data/NEWS
CHANGED
@@ -1,5 +1,23 @@
|
|
1
1
|
# @markup markdown
|
2
2
|
|
3
|
+
2.2.13 (2024-07-27)
|
4
|
+
===================
|
5
|
+
|
6
|
+
- Binary gems for Windows x64 and x86 supports ruby 2.7 - 3.3 inclusive.
|
7
|
+
|
8
|
+
Fixed issues
|
9
|
+
------------
|
10
|
+
|
11
|
+
- Fix various issues about `OCI8.properties[:tcp_keepalive_time]` on macOS arm64. The feature was removed on the platform
|
12
|
+
and it raises `NotImplementedError` instead now.
|
13
|
+
- Fix SIGSEGV when using truffleruby. It seems to be caused by `xfree()` outside of ruby threads.
|
14
|
+
|
15
|
+
Changes
|
16
|
+
-------
|
17
|
+
|
18
|
+
- Change the format of fifth numeral of Oracle version number as two digit zero-padding number
|
19
|
+
when the Oracle version is 23 or upper. For example "23.4.0.24.05".
|
20
|
+
|
3
21
|
2.2.12 (2022-12-30)
|
4
22
|
===================
|
5
23
|
|
data/ext/oci8/extconf.rb
CHANGED
data/ext/oci8/oci8.c
CHANGED
@@ -437,7 +437,7 @@ typedef struct {
|
|
437
437
|
|
438
438
|
static void *complex_logoff_prepare(oci8_svcctx_t *svcctx)
|
439
439
|
{
|
440
|
-
complex_logoff_arg_t *cla =
|
440
|
+
complex_logoff_arg_t *cla = malloc(sizeof(complex_logoff_arg_t));
|
441
441
|
cla->svchp = svcctx->base.hp.svc;
|
442
442
|
cla->usrhp = svcctx->usrhp;
|
443
443
|
cla->srvhp = svcctx->srvhp;
|
@@ -479,7 +479,7 @@ static void *complex_logoff_execute(void *arg)
|
|
479
479
|
if (cla->svchp != NULL) {
|
480
480
|
OCIHandleFree(cla->svchp, OCI_HTYPE_SVCCTX);
|
481
481
|
}
|
482
|
-
|
482
|
+
free(cla);
|
483
483
|
return (void*)(VALUE)rv;
|
484
484
|
}
|
485
485
|
|
data/ext/oci8/oci8.h
CHANGED
@@ -29,11 +29,12 @@ extern "C"
|
|
29
29
|
* hexadecimal -> dotted version number hexadecimal -> dotted version number
|
30
30
|
* 0c102304 -> 12.1.2.3.4 12012034 -> 18.1.2.3.4
|
31
31
|
* ^ ^ ^ ^ ^ ^ ^ ^ ^ ^
|
32
|
-
* 0c ------------' | | | |
|
33
|
-
* 1 --------------' | | |
|
34
|
-
* 02 --------------' | |
|
35
|
-
* 3 ---------------' |
|
36
|
-
* 04 ---------------'
|
32
|
+
* 0c ------------' | | | | 8 bits 12 ------------' | | | | 8 bits
|
33
|
+
* 1 --------------' | | | 4 bits 01 -------------' | | | 8 bits
|
34
|
+
* 02 --------------' | | 8 bits 2 --------------' | | 4 bits
|
35
|
+
* 3 ---------------' | 4 bits 03 --------------' | 8 bits
|
36
|
+
* 04 ---------------' 8 bits 4 ---------------' 4 bits
|
37
|
+
* total 32 bits total 32 bits
|
37
38
|
*/
|
38
39
|
#define ORAVERNUM(major, minor, update, patch, port_update) \
|
39
40
|
(((major) >= 18) ? (((major) << 24) | ((minor) << 16) | ((update) << 12) | ((patch) << 4) | (port_update)) \
|
data/ext/oci8/oci8lib.c
CHANGED
@@ -675,28 +675,7 @@ void *oci8_find_symbol(const char *symbol_name)
|
|
675
675
|
|
676
676
|
void *oci8_check_typeddata(VALUE obj, const oci8_handle_data_type_t *data_type, int error_if_closed)
|
677
677
|
{
|
678
|
-
#ifdef HAVE_RB_DATA_TYPE_T_FUNCTION
|
679
678
|
oci8_base_t *hp = Check_TypedStruct(obj, &data_type->rb_data_type);
|
680
|
-
#else
|
681
|
-
oci8_base_t *hp;
|
682
|
-
const char *expected_type_name = data_type->rb_data_type.wrap_struct_name;
|
683
|
-
const rb_data_type_t *rb_data_type;
|
684
|
-
const rb_data_type_t *expected_rb_data_type = &data_type->rb_data_type;
|
685
|
-
|
686
|
-
if (TYPE(obj) != T_DATA || !rb_obj_is_kind_of(obj, oci8_cOCIHandle)) {
|
687
|
-
rb_raise(rb_eTypeError, "wrong argument type %s (expected %s)",
|
688
|
-
rb_obj_classname(obj), expected_type_name);
|
689
|
-
}
|
690
|
-
hp = DATA_PTR(obj);
|
691
|
-
rb_data_type = &hp->data_type->rb_data_type;
|
692
|
-
while (rb_data_type != expected_rb_data_type) {
|
693
|
-
if (rb_data_type == NULL) {
|
694
|
-
rb_raise(rb_eTypeError, "wrong argument type %s (expected %s)",
|
695
|
-
rb_obj_classname(obj), expected_type_name);
|
696
|
-
}
|
697
|
-
rb_data_type = rb_data_type->parent;
|
698
|
-
}
|
699
|
-
#endif
|
700
679
|
if (error_if_closed && hp->closed) {
|
701
680
|
rb_raise(eOCIException, "%s was already closed.",
|
702
681
|
rb_obj_classname(obj));
|
data/ext/oci8/oraconf.rb
CHANGED
@@ -130,6 +130,8 @@ class MiniSOReader
|
|
130
130
|
@cpu = :ia64
|
131
131
|
when 62
|
132
132
|
@cpu = :x86_64
|
133
|
+
when 183
|
134
|
+
@cpu = :aarch64
|
133
135
|
else
|
134
136
|
raise "Invalid ELF archtype: #{archtype}"
|
135
137
|
end
|
@@ -379,6 +381,8 @@ EOS
|
|
379
381
|
@@ld_envs = %w[PATH]
|
380
382
|
so_ext = 'dll'
|
381
383
|
check_proc = make_proc_to_check_cpu(is_32bit ? :i386 : :x86_64)
|
384
|
+
when /aarch64-linux/
|
385
|
+
check_proc = make_proc_to_check_cpu(:aarch64)
|
382
386
|
when /i.86-linux/
|
383
387
|
check_proc = make_proc_to_check_cpu(:i386)
|
384
388
|
when /ia64-linux/
|
data/ext/oci8/oradate.c
CHANGED
@@ -61,18 +61,7 @@ typedef struct ora_date ora_date_t;
|
|
61
61
|
if (sec < 0 || 59 < sec) \
|
62
62
|
rb_raise(rb_eRangeError, "Out of range for second %d (expect 0 .. 59)", sec)
|
63
63
|
|
64
|
-
#ifdef HAVE_RB_DATA_TYPE_T_FUNCTION
|
65
64
|
#define check_oradate(obj) ((ora_date_t*)Check_TypedStruct((obj), &odate_data_type))
|
66
|
-
#else
|
67
|
-
static ora_date_t *check_oradate(VALUE obj)
|
68
|
-
{
|
69
|
-
if (!rb_obj_is_kind_of(obj, cOraDate)) {
|
70
|
-
rb_raise(rb_eTypeError, "wrong argument type %s (expected %s)",
|
71
|
-
rb_obj_classname(obj), rb_class2name(cOraDate));
|
72
|
-
}
|
73
|
-
return DATA_PTR(obj);
|
74
|
-
}
|
75
|
-
#endif
|
76
65
|
|
77
66
|
static size_t odate_memsize(const void *ptr)
|
78
67
|
{
|