puma 3.12.5-java → 3.12.6-java
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of puma might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/ext/puma_http11/http11_parser.c +3 -1
- data/ext/puma_http11/http11_parser.rl +3 -1
- data/lib/puma/const.rb +1 -1
- data/lib/puma/puma_http11.jar +0 -0
- data/lib/puma/server.rb +31 -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: 5b02ea90141e52839bd36eedaff4e1064824a6c147571bab7fca3578547127eb
|
4
|
+
data.tar.gz: 1f5652c39e101a7c412f5b3f3a3829b925bda5302cb0e5f12a84ae44c748528d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 76d82ddad2ca48e4c46992c665af0abcf1dcf734a4b370033e7928f21e71d0368074cd108c94e5c076e58cbf129ad8a72464537167ab0ae39e437f0ef5c6df50
|
7
|
+
data.tar.gz: 3739c36e080c6fb7c471a43c8edb153887deb85d1c7943a88ca42f3c8ab00340207405eef5008a84e2e04dfb1fee1be694575801af2a1e7878868e1958182f3b
|
@@ -14,12 +14,14 @@
|
|
14
14
|
|
15
15
|
/*
|
16
16
|
* capitalizes all lower-case ASCII characters,
|
17
|
-
* converts dashes to underscores.
|
17
|
+
* converts dashes to underscores, and underscores to commas.
|
18
18
|
*/
|
19
19
|
static void snake_upcase_char(char *c)
|
20
20
|
{
|
21
21
|
if (*c >= 'a' && *c <= 'z')
|
22
22
|
*c &= ~0x20;
|
23
|
+
else if (*c == '_')
|
24
|
+
*c = ',';
|
23
25
|
else if (*c == '-')
|
24
26
|
*c = '_';
|
25
27
|
}
|
@@ -12,12 +12,14 @@
|
|
12
12
|
|
13
13
|
/*
|
14
14
|
* capitalizes all lower-case ASCII characters,
|
15
|
-
* converts dashes to underscores.
|
15
|
+
* converts dashes to underscores, and underscores to commas.
|
16
16
|
*/
|
17
17
|
static void snake_upcase_char(char *c)
|
18
18
|
{
|
19
19
|
if (*c >= 'a' && *c <= 'z')
|
20
20
|
*c &= ~0x20;
|
21
|
+
else if (*c == '_')
|
22
|
+
*c = ',';
|
21
23
|
else if (*c == '-')
|
22
24
|
*c = '_';
|
23
25
|
}
|
data/lib/puma/const.rb
CHANGED
@@ -100,7 +100,7 @@ module Puma
|
|
100
100
|
# too taxing on performance.
|
101
101
|
module Const
|
102
102
|
|
103
|
-
PUMA_VERSION = VERSION = "3.12.
|
103
|
+
PUMA_VERSION = VERSION = "3.12.6".freeze
|
104
104
|
CODE_NAME = "Llamas in Pajamas".freeze
|
105
105
|
PUMA_SERVER_STRING = ['puma', PUMA_VERSION, CODE_NAME].join(' ').freeze
|
106
106
|
|
data/lib/puma/puma_http11.jar
CHANGED
Binary file
|
data/lib/puma/server.rb
CHANGED
@@ -665,6 +665,37 @@ module Puma
|
|
665
665
|
}
|
666
666
|
end
|
667
667
|
|
668
|
+
# Fixup any headers with , in the name to have _ now. We emit
|
669
|
+
# headers with , in them during the parse phase to avoid ambiguity
|
670
|
+
# with the - to _ conversion for critical headers. But here for
|
671
|
+
# compatibility, we'll convert them back. This code is written to
|
672
|
+
# avoid allocation in the common case (ie there are no headers
|
673
|
+
# with , in their names), that's why it has the extra conditionals.
|
674
|
+
|
675
|
+
to_delete = nil
|
676
|
+
to_add = nil
|
677
|
+
|
678
|
+
env.each do |k,v|
|
679
|
+
if k.start_with?("HTTP_") and k.include?(",") and k != "HTTP_TRANSFER,ENCODING"
|
680
|
+
if to_delete
|
681
|
+
to_delete << k
|
682
|
+
else
|
683
|
+
to_delete = [k]
|
684
|
+
end
|
685
|
+
|
686
|
+
unless to_add
|
687
|
+
to_add = {}
|
688
|
+
end
|
689
|
+
|
690
|
+
to_add[k.gsub(",", "_")] = v
|
691
|
+
end
|
692
|
+
end
|
693
|
+
|
694
|
+
if to_delete
|
695
|
+
to_delete.each { |k| env.delete(k) }
|
696
|
+
env.merge! to_add
|
697
|
+
end
|
698
|
+
|
668
699
|
# A rack extension. If the app writes #call'ables to this
|
669
700
|
# array, we will invoke them when the request is done.
|
670
701
|
#
|