puma 4.1.1 → 4.3.6

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e85f11b3b0951de326c5bba3f9f11c77bd1f4b28d6bc82d0f33ba8c6f7ebfd2d
4
- data.tar.gz: 481c1977d845730e2fe5f1186861b6e31f6fe5141f9b90b1d5269a4fcb293657
3
+ metadata.gz: d378ab70a4eac21fe4bf571b95b655d6cbc590b2b91ac323f849986bf8f7ad6c
4
+ data.tar.gz: 1b288cc39f5d80119dde26e844490e572b5f1043060060a1a1d70180743123c3
5
5
  SHA512:
6
- metadata.gz: 25f5a271f646bb1d4695279a5fa21a5be43639a01bcd6647adc484f84e84fc2a227097278da57456bf81de4996c749c0f6c80f9fd249e24a79555e44431bb19b
7
- data.tar.gz: 2defc82769f5c36810f21aaf3f93aaad52e9073e55cb8f19aa0dbc4cfc2dcab37fd0cf458aef58b2025626ff4a59174aff7fa0faa9ebe5a3333fa7dd69ff5df7
6
+ metadata.gz: b63ddad40bdeae9c86d62af5bf044238e273cbf8e95ff944d7b0a736dd39532dfe3b562a77c97b14f86d8e3f916b7cb94ccdbf898e75c4088d075d20e83744d5
7
+ data.tar.gz: abc975210626407c096848540f068a9731ecdc5191327b3ad87355ef4b88b6ac2605ccc7e31ca5398cd787cf9a34efdffc501afe61a2542cc322768af7b26830
data/History.md CHANGED
@@ -1,10 +1,64 @@
1
- ## Master
1
+ ## 4.3.6 / 2020-09-05
2
+
3
+ * Bugfixes
4
+ * Explicitly include ctype.h to fix compilation warning and build error on macOS with Xcode 12 (#2304)
5
+ * Don't require json at boot (#2269)
6
+
7
+ ## 4.3.4/4.3.5 and 3.12.5/3.12.6 / 2020-05-22
8
+
9
+ Each patchlevel release contains a separate security fix. We recommend simply upgrading to 4.3.5/3.12.6.
10
+
11
+ ## 4.3.3 and 3.12.4 / 2020-02-28
12
+ * Bugfixes
13
+ * Fix: Fixes a problem where we weren't splitting headers correctly on newlines (#2132)
14
+ * Security
15
+ * Fix: Prevent HTTP Response splitting via CR in early hints.
16
+
17
+ ## 4.3.2 and 3.12.3 / 2020-02-27
18
+
19
+ * Security
20
+ * Fix: Prevent HTTP Response splitting via CR/LF in header values. CVE-2020-5247.
21
+
22
+ ## 4.3.1 and 3.12.2 / 2019-12-05
23
+
24
+ * Security
25
+ * Fix: a poorly-behaved client could use keepalive requests to monopolize Puma's reactor and create a denial of service attack. CVE-2019-16770.
26
+
27
+ ## 4.3.0 / 2019-11-07
2
28
 
3
29
  * Features
4
- * Your feature goes here (#Github Number)
30
+ * Strip whitespace at end of HTTP headers (#2010)
31
+ * Optimize HTTP parser for JRuby (#2012)
32
+ * Add SSL support for the control app and cli (#2046, #2052)
5
33
 
6
34
  * Bugfixes
7
- * Your bugfix goes here (#Github Number)
35
+ * Fix Errno::EINVAL when SSL is enabled and browser rejects cert (#1564)
36
+ * Fix pumactl defaulting puma to development if an environment was not specified (#2035)
37
+ * Fix closing file stream when reading pid from pidfile (#2048)
38
+ * Fix a typo in configuration option `--extra_runtime_dependencies` (#2050)
39
+
40
+ ## 4.2.1 / 2019-10-07
41
+
42
+ * 3 bugfixes
43
+ * Fix socket activation of systemd (pre-existing) unix binder files (#1842, #1988)
44
+ * Deal with multiple calls to bind correctly (#1986, #1994, #2006)
45
+ * Accepts symbols for `verify_mode` (#1222)
46
+
47
+ ## 4.2.0 / 2019-09-23
48
+
49
+ * 6 features
50
+ * Pumactl has a new -e environment option and reads `config/puma/<environment>.rb` config files (#1885)
51
+ * Semicolons are now allowed in URL paths (MRI only), useful for Angular or Redmine (#1934)
52
+ * Allow extra dependencies to be defined when using prune_bundler (#1105)
53
+ * Puma now reports the correct port when binding to port 0, also reports other listeners when binding to localhost (#1786)
54
+ * Sending SIGINFO to any Puma worker now prints currently active threads and their backtraces (#1320)
55
+ * Puma threads all now have their name set on Ruby 2.3+ (#1968)
56
+ * 4 bugfixes
57
+ * Fix some misbehavior with phased restart and externally SIGTERMed workers (#1908, #1952)
58
+ * Fix socket closing on error (#1941)
59
+ * Removed unnecessary SIGINT trap for JRuby that caused some race conditions (#1961)
60
+ * Fix socket files being left around after process stopped (#1970)
61
+ * Absolutely thousands of lines of test improvements and fixes thanks to @MSP-Greg
8
62
 
9
63
  ## 4.1.1 / 2019-09-05
10
64
 
@@ -15,7 +69,7 @@
15
69
 
16
70
  ## 4.1.0 / 2019-08-08
17
71
 
18
- * 4 features
72
+ * 4 features
19
73
  * Add REQUEST_PATH on parse error message (#1831)
20
74
  * You can now easily add custom log formatters with the `log_formatter` config option (#1816)
21
75
  * Puma.stats now provides process start times (#1844)
@@ -29,17 +83,17 @@
29
83
  * SSL read_nonblock no longer blocks (#1857)
30
84
  * Swallow connection errors when sending early hints (#1822)
31
85
  * Backtrace no longer dumped when invalid pumactl commands are run (#1863)
32
-
33
- * 5 other
86
+
87
+ * 5 other
34
88
  * Avoid casting worker_timeout twice (#1838)
35
89
  * Removed a call to private that wasn't doing anything (#1882)
36
90
  * README, Rakefile, docs and test cleanups (#1848, #1847, #1846, #1853, #1859, #1850, #1866, #1870, #1872, #1833, #1888)
37
91
  * Puma.io has proper documentation now (https://puma.io/puma/)
38
92
  * Added the Contributor Covenant CoC
39
-
40
- * 1 known issue
93
+
94
+ * 1 known issue
41
95
  * Some users are still experiencing issues surrounding socket activation and Unix sockets (#1842)
42
-
96
+
43
97
  ## 4.0.1 / 2019-07-11
44
98
 
45
99
  * 2 bugfixes
@@ -61,7 +115,7 @@
61
115
  * Reactor now uses nio4r instead of `select` (#1728)
62
116
  * Add status to pumactl with pidfile (#1824)
63
117
 
64
- * 9 bugfixes
118
+ * 10 bugfixes
65
119
  * Do not accept new requests on shutdown (#1685, #1808)
66
120
  * Fix 3 corner cases when request body is chunked (#1508)
67
121
  * Change pid existence check's condition branches (#1650)
@@ -71,6 +125,13 @@
71
125
  * Fix Java 8 support (#1773)
72
126
  * Fix error `uninitialized constant Puma::Cluster` (#1731)
73
127
  * Fix `not_token` being able to be set to true (#1803)
128
+ * Fix "Hang on SIGTERM with ruby 2.6 in clustered mode" ([PR #1741], [#1674], [#1720], [#1730], [#1755])
129
+
130
+ [PR #1741]: https://github.com/puma/puma/pull/1741
131
+ [#1674]: https://github.com/puma/puma/issues/1674
132
+ [#1720]: https://github.com/puma/puma/issues/1720
133
+ [#1730]: https://github.com/puma/puma/issues/1730
134
+ [#1755]: https://github.com/puma/puma/issues/1755
74
135
 
75
136
  ## 3.12.1 / 2019-03-19
76
137
 
data/README.md CHANGED
@@ -5,8 +5,9 @@
5
5
  # Puma: A Ruby Web Server Built For Concurrency
6
6
 
7
7
  [![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/puma/puma?utm\_source=badge&utm\_medium=badge&utm\_campaign=pr-badge)
8
- [![Travis Build Status](https://secure.travis-ci.org/puma/puma.svg)](https://travis-ci.org/puma/puma)
9
- [![Appveyor Build Status](https://ci.appveyor.com/api/projects/status/0xnxc7a26u9b2bub/branch/master?svg=true)](https://ci.appveyor.com/project/puma/puma/branch/master)
8
+ [![Actions Build Status](https://github.com/puma/puma/workflows/Puma/badge.svg)](https://github.com/puma/puma/actions)
9
+ [![Travis Build Status](https://travis-ci.org/puma/puma.svg?branch=master)](https://travis-ci.org/puma/puma)
10
+
10
11
  [![Code Climate](https://codeclimate.com/github/puma/puma.svg)](https://codeclimate.com/github/puma/puma)
11
12
  [![SemVer](https://api.dependabot.com/badges/compatibility_score?dependency-name=puma&package-manager=bundler&version-scheme=semver)](https://dependabot.com/compatibility-score.html?dependency-name=puma&package-manager=bundler&version-scheme=semver)
12
13
 
@@ -16,7 +17,7 @@ Puma is a **simple, fast, multi-threaded, and highly concurrent HTTP 1.1 server
16
17
 
17
18
  Puma processes requests using a C-optimized Ragel extension (inherited from Mongrel) that provides fast, accurate HTTP 1.1 protocol parsing in a portable way. Puma then serves the request using a thread pool. Each request is served in a separate thread, so truly concurrent Ruby implementations (JRuby, Rubinius) will use all available CPU cores.
18
19
 
19
- Puma was designed to be the go-to server for [Rubinius](https://rubini.us), but also works well with JRuby and MRI.
20
+ Puma was designed to be the go-to server for [Rubinius](https://rubinius.com), but also works well with JRuby and MRI.
20
21
 
21
22
  On MRI, there is a Global VM Lock (GVL) that ensures only one thread can run Ruby code at a time. But if you're doing a lot of blocking IO (such as HTTP calls to external APIs like Twitter), Puma still improves MRI's throughput by allowing IO waiting to be done in parallel.
22
23
 
@@ -118,17 +119,6 @@ This code can be used to setup the process before booting the application, allow
118
119
  you to do some Puma-specific things that you don't want to embed in your application.
119
120
  For instance, you could fire a log notification that a worker booted or send something to statsd. This can be called multiple times.
120
121
 
121
- If you're preloading your application and using ActiveRecord, it's recommended that you setup your connection pool here:
122
-
123
- ```ruby
124
- # config/puma.rb
125
- on_worker_boot do
126
- ActiveSupport.on_load(:active_record) do
127
- ActiveRecord::Base.establish_connection
128
- end
129
- end
130
- ```
131
-
132
122
  `before_fork` specifies a block to be run before workers are forked:
133
123
 
134
124
  ```ruby
@@ -238,6 +228,8 @@ If you want to prevent Puma from looking for a configuration file in those locat
238
228
  $ puma -C "-"
239
229
  ```
240
230
 
231
+ The other side-effects of setting the environment are whether to show stack traces (in `development` or `test`), and setting RACK_ENV may potentially affect middleware looking for this value to change their behavior. The default puma RACK_ENV value is `development`. You can see all config default values [here](https://github.com/puma/puma/blob/12d1706ddc71b89ed2ee26275e31c788e94ff541/lib/puma/configuration.rb#L170).
232
+
241
233
  Check out [dsl.rb](https://github.com/puma/puma/blob/master/lib/puma/dsl.rb) to see all available options.
242
234
 
243
235
  ## Restart
@@ -290,30 +282,9 @@ reliability in production environments:
290
282
 
291
283
  ## Contributing
292
284
 
293
- To run the test suite:
294
-
295
- ```bash
296
- $ bundle install
297
- $ bundle exec rake
298
- ```
299
-
300
- To run a single test file, use the `TEST` environment variable:
301
-
302
- ```bash
303
- $ TEST=test/test_binder.rb bundle exec rake test
304
- ```
305
-
306
- Or use [`m`](https://github.com/qrush/m):
285
+ Find details for contributing in the [contribution guide].
307
286
 
308
- ```
309
- $ bundle exec m test/test_binder.rb
310
- ```
311
-
312
- Which can also be used to run a single test case:
313
-
314
- ```
315
- $ bundle exec m test/test_binder.rb:37
316
- ```
287
+ [contribution guide]: https://github.com/puma/puma/blob/master/CONTRIBUTING.md
317
288
 
318
289
  ## License
319
290
 
@@ -1,15 +1,22 @@
1
1
  ## Plugins
2
2
 
3
- Puma 3.0 added support for plugins that can augment configuration and service operations.
3
+ Puma 3.0 added support for plugins that can augment configuration and service
4
+ operations.
4
5
 
5
6
  2 canonical plugins to look to aid in development of further plugins:
6
7
 
7
- * [tmp\_restart](https://github.com/puma/puma/blob/master/lib/puma/plugin/tmp_restart.rb): Restarts the server if the file `tmp/restart.txt` is touched
8
- * [heroku](https://github.com/puma/puma-heroku/blob/master/lib/puma/plugin/heroku.rb): Packages up the default configuration used by puma on Heroku
8
+ * [tmp\_restart](https://github.com/puma/puma/blob/master/lib/puma/plugin/tmp_restart.rb):
9
+ Restarts the server if the file `tmp/restart.txt` is touched
10
+ * [heroku](https://github.com/puma/puma-heroku/blob/master/lib/puma/plugin/heroku.rb):
11
+ Packages up the default configuration used by puma on Heroku
9
12
 
10
- Plugins are activated in a puma configuration file (such as `config/puma.rb'`) by adding `plugin "name"`, such as `plugin "heroku"`.
13
+ Plugins are activated in a puma configuration file (such as `config/puma.rb'`)
14
+ by adding `plugin "name"`, such as `plugin "heroku"`.
11
15
 
12
- Plugins are activated based simply on path requirements so, activating the `heroku` plugin will simply be doing `require "puma/plugin/heroku"`. This allows gems to provide multiple plugins (as well as unrelated gems to provide puma plugins).
16
+ Plugins are activated based simply on path requirements so, activating the
17
+ `heroku` plugin will simply be doing `require "puma/plugin/heroku"`. This
18
+ allows gems to provide multiple plugins (as well as unrelated gems to provide
19
+ puma plugins).
13
20
 
14
21
  The `tmp_restart` plugin is bundled with puma, so it can always be used.
15
22
 
@@ -17,12 +24,15 @@ To use the `heroku` plugin, add `puma-heroku` to your Gemfile or install it.
17
24
 
18
25
  ### API
19
26
 
20
- At present, there are 2 hooks that plugins can use: `start` and `config`.
27
+ ## Server-wide hooks
21
28
 
22
- `start` runs when the server has started and allows the plugin to start other functionality to augment puma.
29
+ Plugins can use a couple of hooks at server level: `start` and `config`.
23
30
 
24
- `config` runs when the server is being configured and is passed a `Puma::DSL` object that can be used to add additional configuration.
31
+ `start` runs when the server has started and allows the plugin to start other
32
+ functionality to augment puma.
25
33
 
26
- Any public methods in `Puma::Plugin` are the public API that any plugin may use.
34
+ `config` runs when the server is being configured and is passed a `Puma::DSL`
35
+ object that can be used to add additional configuration.
27
36
 
28
- In the future, more hooks and APIs will be added.
37
+ Any public methods in `Puma::Plugin` are the public API that any plugin may
38
+ use.
@@ -0,0 +1,96 @@
1
+ # TCP mode
2
+
3
+ Puma also could be used as a TCP server to process incoming TCP
4
+ connections.
5
+
6
+
7
+ ## Configuration
8
+
9
+ TCP mode can be enabled with CLI option `--tcp-mode`:
10
+
11
+ ```
12
+ $ puma --tcp-mode
13
+ ```
14
+
15
+ Default ip and port to listen to are `0.0.0.0` and `9292`. You can configure
16
+ them with `--port` and `--bind` options:
17
+
18
+ ```
19
+ $ puma --tcp-mode --bind tcp://127.0.0.1:9293
20
+ $ puma --tcp-mode --port 9293
21
+ ```
22
+
23
+ TCP mode could be set with a configuration file as well with `tcp_mode`
24
+ and `tcp_mode!` methods:
25
+
26
+ ```
27
+ # config/puma.rb
28
+ tcp_mode
29
+ ```
30
+
31
+ When Puma starts in the TCP mode it prints the corresponding message:
32
+
33
+ ```
34
+ puma --tcp-mode
35
+ Puma starting in single mode...
36
+ ...
37
+ * Mode: Lopez Express (tcp)
38
+ ```
39
+
40
+
41
+ ## How to declare an application
42
+
43
+ An application to process TCP connections should be declared as a
44
+ callable object which accepts `env` and `socket` arguments.
45
+
46
+ `env` argument is a Hash with following structure:
47
+
48
+ ```ruby
49
+ { "thread" => {}, "REMOTE_ADDR" => "127.0.0.1:51133", "log" => "#<Proc:0x000..." }
50
+ ```
51
+
52
+ It consists of:
53
+ * `thread` - a Hash for each thread in the thread pool that could be
54
+ used to store information between requests
55
+ * `REMOTE_ADDR` - a client ip address
56
+ * `log` - a proc object to write something down
57
+
58
+ `log` object could be used this way:
59
+
60
+ ```ruby
61
+ env['log'].call('message to log')
62
+ #> 19/Oct/2019 20:28:53 - 127.0.0.1:51266 - message to log
63
+ ```
64
+
65
+
66
+ ## Example of an application
67
+
68
+ Let's look at an example of a simple application which just echoes
69
+ incoming string:
70
+
71
+ ```ruby
72
+ # config/puma.rb
73
+ app do |env, socket|
74
+ s = socket.gets
75
+ socket.puts "Echo #{s}"
76
+ end
77
+ ```
78
+
79
+ We can easily access the TCP server with `telnet` command and receive an
80
+ echo:
81
+
82
+ ```shell
83
+ telnet 0.0.0.0 9293
84
+ Trying 0.0.0.0...
85
+ Connected to 0.0.0.0.
86
+ Escape character is '^]'.
87
+ sssss
88
+ Echo sssss
89
+ ^CConnection closed by foreign host.
90
+ ```
91
+
92
+
93
+ ## Socket management
94
+
95
+ After the application finishes, Puma closes the socket. In order to
96
+ prevent this, the application should set `env['detach'] = true`.
@@ -1,6 +1,11 @@
1
1
  require 'mkmf'
2
2
 
3
3
  dir_config("puma_http11")
4
+ if RUBY_PLATFORM[/mingw32/]
5
+ append_cflags '-D_FORTIFY_SOURCE=2'
6
+ append_ldflags '-fstack-protector'
7
+ have_library 'ssp'
8
+ end
4
9
 
5
10
  unless ENV["DISABLE_SSL"]
6
11
  dir_config("openssl")
@@ -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
  }
@@ -38,7 +40,7 @@ static void snake_upcase_char(char *c)
38
40
 
39
41
  #line 40 "ext/puma_http11/http11_parser.c"
40
42
  static const int puma_parser_start = 1;
41
- static const int puma_parser_first_final = 47;
43
+ static const int puma_parser_first_final = 46;
42
44
  static const int puma_parser_error = 0;
43
45
 
44
46
  static const int puma_parser_en_main = 1;
@@ -117,17 +119,17 @@ case 2:
117
119
  #line 118 "ext/puma_http11/http11_parser.c"
118
120
  switch( (*p) ) {
119
121
  case 32: goto tr2;
120
- case 36: goto st28;
121
- case 95: goto st28;
122
+ case 36: goto st27;
123
+ case 95: goto st27;
122
124
  }
123
125
  if ( (*p) < 48 ) {
124
126
  if ( 45 <= (*p) && (*p) <= 46 )
125
- goto st28;
127
+ goto st27;
126
128
  } else if ( (*p) > 57 ) {
127
129
  if ( 65 <= (*p) && (*p) <= 90 )
128
- goto st28;
130
+ goto st27;
129
131
  } else
130
- goto st28;
132
+ goto st27;
131
133
  goto st0;
132
134
  tr2:
133
135
  #line 48 "ext/puma_http11/http11_parser.rl"
@@ -199,7 +201,7 @@ tr37:
199
201
  parser->request_uri(parser, PTR_TO(mark), LEN(mark, p));
200
202
  }
201
203
  goto st5;
202
- tr44:
204
+ tr41:
203
205
  #line 58 "ext/puma_http11/http11_parser.rl"
204
206
  { MARK(query_start, p); }
205
207
  #line 59 "ext/puma_http11/http11_parser.rl"
@@ -211,7 +213,7 @@ tr44:
211
213
  parser->request_uri(parser, PTR_TO(mark), LEN(mark, p));
212
214
  }
213
215
  goto st5;
214
- tr47:
216
+ tr44:
215
217
  #line 59 "ext/puma_http11/http11_parser.rl"
216
218
  {
217
219
  parser->query_string(parser, PTR_TO(query_start), LEN(query_start, p));
@@ -362,13 +364,13 @@ tr22:
362
364
  {
363
365
  parser->body_start = p - buffer + 1;
364
366
  parser->header_done(parser, p + 1, pe - p - 1);
365
- {p++; cs = 47; goto _out;}
367
+ {p++; cs = 46; goto _out;}
366
368
  }
367
- goto st47;
368
- st47:
369
+ goto st46;
370
+ st46:
369
371
  if ( ++p == pe )
370
- goto _test_eof47;
371
- case 47:
372
+ goto _test_eof46;
373
+ case 46:
372
374
  #line 373 "ext/puma_http11/http11_parser.c"
373
375
  goto st0;
374
376
  tr21:
@@ -458,7 +460,7 @@ tr38:
458
460
  parser->request_uri(parser, PTR_TO(mark), LEN(mark, p));
459
461
  }
460
462
  goto st20;
461
- tr45:
463
+ tr42:
462
464
  #line 58 "ext/puma_http11/http11_parser.rl"
463
465
  { MARK(query_start, p); }
464
466
  #line 59 "ext/puma_http11/http11_parser.rl"
@@ -470,7 +472,7 @@ tr45:
470
472
  parser->request_uri(parser, PTR_TO(mark), LEN(mark, p));
471
473
  }
472
474
  goto st20;
473
- tr48:
475
+ tr45:
474
476
  #line 59 "ext/puma_http11/http11_parser.rl"
475
477
  {
476
478
  parser->query_string(parser, PTR_TO(query_start), LEN(query_start, p));
@@ -576,10 +578,9 @@ case 24:
576
578
  case 32: goto tr37;
577
579
  case 34: goto st0;
578
580
  case 35: goto tr38;
579
- case 59: goto tr39;
580
581
  case 60: goto st0;
581
582
  case 62: goto st0;
582
- case 63: goto tr40;
583
+ case 63: goto tr39;
583
584
  case 127: goto st0;
584
585
  }
585
586
  if ( 0 <= (*p) && (*p) <= 31 )
@@ -595,30 +596,27 @@ st25:
595
596
  if ( ++p == pe )
596
597
  goto _test_eof25;
597
598
  case 25:
598
- #line 599 "ext/puma_http11/http11_parser.c"
599
+ #line 598 "ext/puma_http11/http11_parser.c"
599
600
  switch( (*p) ) {
600
- case 32: goto tr8;
601
+ case 32: goto tr41;
601
602
  case 34: goto st0;
602
- case 35: goto tr9;
603
+ case 35: goto tr42;
603
604
  case 60: goto st0;
604
605
  case 62: goto st0;
605
- case 63: goto st26;
606
606
  case 127: goto st0;
607
607
  }
608
608
  if ( 0 <= (*p) && (*p) <= 31 )
609
609
  goto st0;
610
- goto st25;
610
+ goto tr40;
611
611
  tr40:
612
- #line 67 "ext/puma_http11/http11_parser.rl"
613
- {
614
- parser->request_path(parser, PTR_TO(mark), LEN(mark,p));
615
- }
612
+ #line 58 "ext/puma_http11/http11_parser.rl"
613
+ { MARK(query_start, p); }
616
614
  goto st26;
617
615
  st26:
618
616
  if ( ++p == pe )
619
617
  goto _test_eof26;
620
618
  case 26:
621
- #line 622 "ext/puma_http11/http11_parser.c"
619
+ #line 618 "ext/puma_http11/http11_parser.c"
622
620
  switch( (*p) ) {
623
621
  case 32: goto tr44;
624
622
  case 34: goto st0;
@@ -629,27 +627,25 @@ case 26:
629
627
  }
630
628
  if ( 0 <= (*p) && (*p) <= 31 )
631
629
  goto st0;
632
- goto tr43;
633
- tr43:
634
- #line 58 "ext/puma_http11/http11_parser.rl"
635
- { MARK(query_start, p); }
636
- goto st27;
630
+ goto st26;
637
631
  st27:
638
632
  if ( ++p == pe )
639
633
  goto _test_eof27;
640
634
  case 27:
641
- #line 642 "ext/puma_http11/http11_parser.c"
642
635
  switch( (*p) ) {
643
- case 32: goto tr47;
644
- case 34: goto st0;
645
- case 35: goto tr48;
646
- case 60: goto st0;
647
- case 62: goto st0;
648
- case 127: goto st0;
636
+ case 32: goto tr2;
637
+ case 36: goto st28;
638
+ case 95: goto st28;
649
639
  }
650
- if ( 0 <= (*p) && (*p) <= 31 )
651
- goto st0;
652
- goto st27;
640
+ if ( (*p) < 48 ) {
641
+ if ( 45 <= (*p) && (*p) <= 46 )
642
+ goto st28;
643
+ } else if ( (*p) > 57 ) {
644
+ if ( 65 <= (*p) && (*p) <= 90 )
645
+ goto st28;
646
+ } else
647
+ goto st28;
648
+ goto st0;
653
649
  st28:
654
650
  if ( ++p == pe )
655
651
  goto _test_eof28;
@@ -960,24 +956,6 @@ st45:
960
956
  if ( ++p == pe )
961
957
  goto _test_eof45;
962
958
  case 45:
963
- switch( (*p) ) {
964
- case 32: goto tr2;
965
- case 36: goto st46;
966
- case 95: goto st46;
967
- }
968
- if ( (*p) < 48 ) {
969
- if ( 45 <= (*p) && (*p) <= 46 )
970
- goto st46;
971
- } else if ( (*p) > 57 ) {
972
- if ( 65 <= (*p) && (*p) <= 90 )
973
- goto st46;
974
- } else
975
- goto st46;
976
- goto st0;
977
- st46:
978
- if ( ++p == pe )
979
- goto _test_eof46;
980
- case 46:
981
959
  if ( (*p) == 32 )
982
960
  goto tr2;
983
961
  goto st0;
@@ -997,7 +975,7 @@ case 46:
997
975
  _test_eof14: cs = 14; goto _test_eof;
998
976
  _test_eof15: cs = 15; goto _test_eof;
999
977
  _test_eof16: cs = 16; goto _test_eof;
1000
- _test_eof47: cs = 47; goto _test_eof;
978
+ _test_eof46: cs = 46; goto _test_eof;
1001
979
  _test_eof17: cs = 17; goto _test_eof;
1002
980
  _test_eof18: cs = 18; goto _test_eof;
1003
981
  _test_eof19: cs = 19; goto _test_eof;
@@ -1027,7 +1005,6 @@ case 46:
1027
1005
  _test_eof43: cs = 43; goto _test_eof;
1028
1006
  _test_eof44: cs = 44; goto _test_eof;
1029
1007
  _test_eof45: cs = 45; goto _test_eof;
1030
- _test_eof46: cs = 46; goto _test_eof;
1031
1008
 
1032
1009
  _test_eof: {}
1033
1010
  _out: {}