dalli 3.2.16 → 3.2.17
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/CHANGELOG.md +7 -0
- data/lib/dalli/protocol/meta/response_processor.rb +12 -1
- data/lib/dalli/version.rb +1 -1
- metadata +6 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 85605d05fac6cb78fd5b6a3505bf92bb3df72f80a8aecd1fc581896e0bb6bcf5
|
|
4
|
+
data.tar.gz: 3e1d6612ea7c0c8987bc573bc3686d0d29d184b6af2edbd737f14ec6619fc6f0
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 6c037ec54baa774897ada2bbfce9a99f927eca9e9d7655bdfec55b56118939d6ba212057ebcaada26dc7d6761a5e2926dcbe2b018e3eb0ba249bb650a1f864ce
|
|
7
|
+
data.tar.gz: 2cc9822465193504397dc0af9130eabf49b08887a77ca4dd37c86160e9043b6611eb4c3eddc91275dc4a341330d4d3430bff04a7087c4272c89da5c0e31a9270
|
data/CHANGELOG.md
CHANGED
|
@@ -176,6 +176,9 @@ module Dalli
|
|
|
176
176
|
# a complete response, don't advance the buffer
|
|
177
177
|
return [0, nil, nil, nil, nil] unless buf.bytesize >= resp_size
|
|
178
178
|
|
|
179
|
+
term = header_len + body_len
|
|
180
|
+
raise_bad_value_terminator unless buf.getbyte(term) == 13 && buf.getbyte(term + 1) == 10
|
|
181
|
+
|
|
179
182
|
# The full response is in our buffer, so parse it and return
|
|
180
183
|
# the values
|
|
181
184
|
body = buf.slice(header_len, body_len)
|
|
@@ -266,11 +269,19 @@ module Dalli
|
|
|
266
269
|
|
|
267
270
|
# Values are read by the size in the VA line, not up to the next CRLF:
|
|
268
271
|
# a value can contain CRLF and can be longer than MAX_LINE_BYTES
|
|
272
|
+
def strip_value_terminator!(data)
|
|
273
|
+
data&.chomp!(TERMINATOR) || raise_bad_value_terminator
|
|
274
|
+
end
|
|
275
|
+
|
|
276
|
+
def raise_bad_value_terminator
|
|
277
|
+
raise Dalli::DalliError, "Reply value isn't followed by CRLF, so its size doesn't match the value"
|
|
278
|
+
end
|
|
279
|
+
|
|
269
280
|
def read_data(data_size)
|
|
270
281
|
# Checked before the terminator is added: -1 or -2 would otherwise
|
|
271
282
|
# read 1 or 0 bytes and leave the connection out of step
|
|
272
283
|
check_value_size!(data_size)
|
|
273
|
-
@io_source.read(data_size + TERMINATOR.bytesize)
|
|
284
|
+
strip_value_terminator!(@io_source.read(data_size + TERMINATOR.bytesize))
|
|
274
285
|
end
|
|
275
286
|
end
|
|
276
287
|
end
|
data/lib/dalli/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: dalli
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 3.2.
|
|
4
|
+
version: 3.2.17
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Peter M. Goldstein
|
|
8
8
|
- Mike Perham
|
|
9
|
+
autorequire:
|
|
9
10
|
bindir: bin
|
|
10
11
|
cert_chain: []
|
|
11
|
-
date:
|
|
12
|
+
date: 2026-11-14 00:00:00.000000000 Z
|
|
12
13
|
dependencies:
|
|
13
14
|
- !ruby/object:Gem::Dependency
|
|
14
15
|
name: logger
|
|
@@ -76,6 +77,7 @@ metadata:
|
|
|
76
77
|
bug_tracker_uri: https://github.com/petergoldstein/dalli/issues
|
|
77
78
|
changelog_uri: https://github.com/petergoldstein/dalli/blob/main/CHANGELOG.md
|
|
78
79
|
rubygems_mfa_required: 'true'
|
|
80
|
+
post_install_message:
|
|
79
81
|
rdoc_options: []
|
|
80
82
|
require_paths:
|
|
81
83
|
- lib
|
|
@@ -90,7 +92,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
90
92
|
- !ruby/object:Gem::Version
|
|
91
93
|
version: '0'
|
|
92
94
|
requirements: []
|
|
93
|
-
rubygems_version:
|
|
95
|
+
rubygems_version: 3.5.22
|
|
96
|
+
signing_key:
|
|
94
97
|
specification_version: 4
|
|
95
98
|
summary: High performance memcached client for Ruby
|
|
96
99
|
test_files: []
|