protocol-http2 0.15.0 → 0.15.1

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: 28d53d86975d6aa52e2ea20e36c41fa4e8fff6437ef8b831de001b3d2849609b
4
- data.tar.gz: 6c13193934a0eea767493757ff70e814d68f66fe68af4a774fb22d707e78437d
3
+ metadata.gz: 89961e568533a95a580a7eaa79c9d519a9467016b819739f2868385fb2cb2d2f
4
+ data.tar.gz: 185af0c2c4d5fb02077daf4b5ac1131abb013842f151e24f5b3b0f2b2aef0a60
5
5
  SHA512:
6
- metadata.gz: 13bcd265d3eba3c322cdc6a473955a946a219f9d6f0015607a04248392fccadf70d456b42e1fdc455697678f95a87982e95ca7dda1774468f87dfdb16ed09d4e
7
- data.tar.gz: 1f393c99f5657db925c6ea337ba5190cc722b8e8698d7d30751348b061719c60f905b551a2d60e1d90182a94dae1c2dcbc23eee9c2bf408b46bb0b08faa3799f
6
+ metadata.gz: d0c3233cb4842658ad1e013c004fe043d0dc952eb3404bd91acfe6471c6b686da6bec1f81923202ed725713ad6f4cc603a99418eaf565ad317bd301756e551bc
7
+ data.tar.gz: 72f5fd86a460e9c71cb5d7587c165c7ffe1a8be4f44afd99010e04f7dc18fc85011d5ed723a40a3c3d84831f45acdcfe6e093270938e1dd7066e5acde74dbe9a
checksums.yaml.gz.sig CHANGED
Binary file
@@ -101,6 +101,7 @@ module Protocol
101
101
  @streams.each_value{|stream| stream.close(error)}
102
102
  @streams.clear
103
103
 
104
+ ensure
104
105
  if @framer
105
106
  @framer.close
106
107
  @framer = nil
@@ -29,11 +29,11 @@ module Protocol
29
29
 
30
30
  buffer = String.new.b
31
31
 
32
- buffer << padding_size.chr
32
+ buffer << padding_size
33
33
  buffer << data
34
34
 
35
- if padding_size > 1
36
- buffer << "\0" * (padding_size - 1)
35
+ if padding_size
36
+ buffer << ("\0" * padding_size)
37
37
  end
38
38
 
39
39
  super buffer
@@ -47,7 +47,9 @@ module Protocol
47
47
  def unpack
48
48
  if padded?
49
49
  padding_size = @payload[0].ord
50
- data_size = @payload.bytesize - padding_size
50
+
51
+ # 1 byte for the padding octet, and padding_size bytes for the padding itself:
52
+ data_size = @payload.bytesize - (1 + padding_size)
51
53
 
52
54
  if data_size < 0
53
55
  raise ProtocolError, "Invalid padding length: #{padding_size}"
@@ -5,6 +5,6 @@
5
5
 
6
6
  module Protocol
7
7
  module HTTP2
8
- VERSION = "0.15.0"
8
+ VERSION = "0.15.1"
9
9
  end
10
10
  end
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: protocol-http2
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.15.0
4
+ version: 0.15.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Williams
@@ -40,7 +40,7 @@ cert_chain:
40
40
  Q2K9NVun/S785AP05vKkXZEFYxqG6EW012U4oLcFl5MySFajYXRYbuUpH6AY+HP8
41
41
  voD0MPg1DssDLKwXyt1eKD/+Fq0bFWhwVM/1XiAXL7lyYUyOq24KHgQ2Csg=
42
42
  -----END CERTIFICATE-----
43
- date: 2023-02-02 00:00:00.000000000 Z
43
+ date: 2023-02-12 00:00:00.000000000 Z
44
44
  dependencies:
45
45
  - !ruby/object:Gem::Dependency
46
46
  name: protocol-hpack
@@ -161,7 +161,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
161
161
  - !ruby/object:Gem::Version
162
162
  version: '0'
163
163
  requirements: []
164
- rubygems_version: 3.4.1
164
+ rubygems_version: 3.4.6
165
165
  signing_key:
166
166
  specification_version: 4
167
167
  summary: A low level implementation of the HTTP/2 protocol.
metadata.gz.sig CHANGED
Binary file