sequel_pg 1.16.0 → 1.17.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG +11 -1
- data/ext/sequel_pg/extconf.rb +1 -1
- data/ext/sequel_pg/sequel_pg.c +5 -5
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 56786474673577561d1a782036554d0b76e235e532ef9b59a0ef2d5432b02bbf
|
4
|
+
data.tar.gz: 9c5f8b66b218938fc302e0428f62a3b2817cf7a1994bfc9e08740ed58703b351
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 21eaa799a903c49beb82b0979160b89158990853fe430ad9d491627b926a7706869ad1ade114c1446e6fb0b379bede780505155d0780b89d8d77bbecffe25f31
|
7
|
+
data.tar.gz: 750785782d68a8207286b929b0770df17315aa864bfcc25bc318d0562f655c16f636f4541353438ad626f1cd119f0262638386c9b48aae76a159c32c65157a7d
|
data/CHANGELOG
CHANGED
@@ -1,6 +1,16 @@
|
|
1
|
+
=== 1.17.1 (2023-01-05)
|
2
|
+
|
3
|
+
* Modify LDFLAGS when building on MacOS to allow undefined functions (delphaber) (#53)
|
4
|
+
|
5
|
+
=== 1.17.0 (2022-10-05)
|
6
|
+
|
7
|
+
* Do not use pgresult_stream_any when using pg <1.4.4, to avoid double free in certain cases (larskanis) (#50)
|
8
|
+
|
9
|
+
* Support new pgresult_stream_any API in pg 1.4.4 (larskanis) (#50)
|
10
|
+
|
1
11
|
=== 1.16.0 (2022-08-16)
|
2
12
|
|
3
|
-
* Fix memory leak when using streaming with 1.3.4+ (jeremyevans) (#48)
|
13
|
+
* Fix memory leak when using streaming with pg 1.3.4+ (jeremyevans) (#48)
|
4
14
|
|
5
15
|
* Modify LDFLAGS when building on MacOS arm64 to allow undefined functions (maxsz) (#46)
|
6
16
|
|
data/ext/sequel_pg/extconf.rb
CHANGED
@@ -2,7 +2,7 @@ require 'mkmf'
|
|
2
2
|
$CFLAGS << " -O0 -g" if ENV['DEBUG']
|
3
3
|
$CFLAGS << " -Drb_tainted_str_new=rb_str_new -DNO_TAINT" if RUBY_VERSION >= '2.7'
|
4
4
|
$CFLAGS << " -Wall " unless RUBY_PLATFORM =~ /solaris/
|
5
|
-
$LDFLAGS += " -Wl,-U,_pg_get_pgconn -Wl,-U,_pg_get_result_enc_idx -Wl,-U,_pgresult_get -Wl,-U,_pgresult_stream_any " if RUBY_PLATFORM =~ /
|
5
|
+
$LDFLAGS += " -Wl,-U,_pg_get_pgconn -Wl,-U,_pg_get_result_enc_idx -Wl,-U,_pgresult_get -Wl,-U,_pgresult_stream_any " if RUBY_PLATFORM =~ /darwin/
|
6
6
|
dir_config('pg', ENV["POSTGRES_INCLUDE"] || (IO.popen("pg_config --includedir").readline.chomp rescue nil),
|
7
7
|
ENV["POSTGRES_LIB"] || (IO.popen("pg_config --libdir").readline.chomp rescue nil))
|
8
8
|
|
data/ext/sequel_pg/sequel_pg.c
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
#define SEQUEL_PG_VERSION_INTEGER
|
1
|
+
#define SEQUEL_PG_VERSION_INTEGER 11701
|
2
2
|
|
3
3
|
#include <string.h>
|
4
4
|
#include <stdio.h>
|
@@ -70,7 +70,7 @@
|
|
70
70
|
PGconn* pg_get_pgconn(VALUE);
|
71
71
|
PGresult* pgresult_get(VALUE);
|
72
72
|
int pg_get_result_enc_idx(VALUE);
|
73
|
-
VALUE pgresult_stream_any(VALUE self,
|
73
|
+
VALUE pgresult_stream_any(VALUE self, int (*yielder)(VALUE, int, int, void*), void* data);
|
74
74
|
|
75
75
|
static int spg_use_ipaddr_alloc;
|
76
76
|
static int spg_use_pg_get_result_enc_idx;
|
@@ -1672,7 +1672,7 @@ struct spg__yield_each_row_stream_data {
|
|
1672
1672
|
char type;
|
1673
1673
|
};
|
1674
1674
|
|
1675
|
-
static
|
1675
|
+
static int spg__yield_each_row_stream(VALUE rres, int ntuples, int nfields, void *rdata) {
|
1676
1676
|
struct spg__yield_each_row_stream_data* data = (struct spg__yield_each_row_stream_data *)rdata;
|
1677
1677
|
VALUE h = rb_hash_new();
|
1678
1678
|
VALUE self = data->self;
|
@@ -1693,7 +1693,7 @@ static void spg__yield_each_row_stream(VALUE rres, int ntuples, int nfields, voi
|
|
1693
1693
|
} else {
|
1694
1694
|
rb_yield(h);
|
1695
1695
|
}
|
1696
|
-
|
1696
|
+
return 1; /* clear the result */
|
1697
1697
|
}
|
1698
1698
|
|
1699
1699
|
static VALUE spg__yield_each_row_internal(VALUE self, VALUE rconn, VALUE rres, PGresult *res, int enc_index, VALUE *colsyms, VALUE *colconvert) {
|
@@ -1868,7 +1868,7 @@ void Init_sequel_pg(void) {
|
|
1868
1868
|
if (FIX2INT(RARRAY_AREF(c, 1)) >= 2) {
|
1869
1869
|
spg_use_pg_get_result_enc_idx = 1;
|
1870
1870
|
}
|
1871
|
-
if (FIX2INT(RARRAY_AREF(c, 1)) >
|
1871
|
+
if (FIX2INT(RARRAY_AREF(c, 1)) > 4 || (FIX2INT(RARRAY_AREF(c, 1)) == 4 && FIX2INT(RARRAY_AREF(c, 2)) >= 4)) {
|
1872
1872
|
spg_use_pg_stream_any = 1;
|
1873
1873
|
}
|
1874
1874
|
}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sequel_pg
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.17.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jeremy Evans
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2023-01-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: pg
|
@@ -77,9 +77,9 @@ metadata:
|
|
77
77
|
bug_tracker_uri: https://github.com/jeremyevans/sequel_pg/issues
|
78
78
|
changelog_uri: https://github.com/jeremyevans/sequel_pg/blob/master/CHANGELOG
|
79
79
|
documentation_uri: https://github.com/jeremyevans/sequel_pg/blob/master/README.rdoc
|
80
|
-
mailing_list_uri: https://
|
80
|
+
mailing_list_uri: https://github.com/jeremyevans/sequel_pg/discussions
|
81
81
|
source_code_uri: https://github.com/jeremyevans/sequel_pg
|
82
|
-
post_install_message:
|
82
|
+
post_install_message:
|
83
83
|
rdoc_options:
|
84
84
|
- "--quiet"
|
85
85
|
- "--line-numbers"
|
@@ -101,8 +101,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
101
101
|
- !ruby/object:Gem::Version
|
102
102
|
version: '0'
|
103
103
|
requirements: []
|
104
|
-
rubygems_version: 3.
|
105
|
-
signing_key:
|
104
|
+
rubygems_version: 3.4.1
|
105
|
+
signing_key:
|
106
106
|
specification_version: 4
|
107
107
|
summary: Faster SELECTs when using Sequel with pg
|
108
108
|
test_files: []
|