pitchfork 0.13.0 → 0.14.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -18,6 +18,7 @@
18
18
  #include "child_subreaper.h"
19
19
 
20
20
  void init_pitchfork_httpdate(void);
21
+ void init_pitchfork_memory_page(VALUE);
21
22
 
22
23
  #define UH_FL_CHUNKED 0x1
23
24
  #define UH_FL_HASBODY 0x2
@@ -314,12 +315,12 @@ static void write_value(VALUE self, struct http_parser *hp,
314
315
  /** Machine **/
315
316
 
316
317
 
317
- #line 421 "pitchfork_http.rl"
318
+ #line 422 "pitchfork_http.rl"
318
319
 
319
320
 
320
321
  /** Data **/
321
322
 
322
- #line 323 "pitchfork_http.c"
323
+ #line 324 "pitchfork_http.c"
323
324
  static const int http_parser_start = 1;
324
325
  static const int http_parser_first_final = 122;
325
326
  static const int http_parser_error = 0;
@@ -330,7 +331,7 @@ static const int http_parser_en_Trailers = 114;
330
331
  static const int http_parser_en_main = 1;
331
332
 
332
333
 
333
- #line 425 "pitchfork_http.rl"
334
+ #line 426 "pitchfork_http.rl"
334
335
 
335
336
  static void http_parser_init(struct http_parser *hp)
336
337
  {
@@ -343,12 +344,12 @@ static void http_parser_init(struct http_parser *hp)
343
344
  hp->len.content = 0;
344
345
  hp->cont = Qfalse; /* zero on MRI, should be optimized away by above */
345
346
 
346
- #line 347 "pitchfork_http.c"
347
+ #line 348 "pitchfork_http.c"
347
348
  {
348
349
  cs = http_parser_start;
349
350
  }
350
351
 
351
- #line 437 "pitchfork_http.rl"
352
+ #line 438 "pitchfork_http.rl"
352
353
  hp->cs = cs;
353
354
  }
354
355
 
@@ -376,7 +377,7 @@ http_parser_execute(VALUE self, struct http_parser *hp, char *buffer, size_t len
376
377
  goto skip_chunk_data_hack;
377
378
  }
378
379
 
379
- #line 380 "pitchfork_http.c"
380
+ #line 381 "pitchfork_http.c"
380
381
  {
381
382
  if ( p == pe )
382
383
  goto _test_eof;
@@ -411,14 +412,14 @@ st0:
411
412
  cs = 0;
412
413
  goto _out;
413
414
  tr0:
414
- #line 317 "pitchfork_http.rl"
415
+ #line 318 "pitchfork_http.rl"
415
416
  {MARK(mark, p); }
416
417
  goto st2;
417
418
  st2:
418
419
  if ( ++p == pe )
419
420
  goto _test_eof2;
420
421
  case 2:
421
- #line 422 "pitchfork_http.c"
422
+ #line 423 "pitchfork_http.c"
422
423
  switch( (*p) ) {
423
424
  case 32: goto tr3;
424
425
  case 33: goto st49;
@@ -444,14 +445,14 @@ case 2:
444
445
  goto st49;
445
446
  goto st0;
446
447
  tr3:
447
- #line 326 "pitchfork_http.rl"
448
+ #line 327 "pitchfork_http.rl"
448
449
  { request_method(hp, PTR_TO(mark), LEN(mark, p)); }
449
450
  goto st3;
450
451
  st3:
451
452
  if ( ++p == pe )
452
453
  goto _test_eof3;
453
454
  case 3:
454
- #line 455 "pitchfork_http.c"
455
+ #line 456 "pitchfork_http.c"
455
456
  switch( (*p) ) {
456
457
  case 42: goto tr5;
457
458
  case 47: goto tr6;
@@ -460,21 +461,21 @@ case 3:
460
461
  }
461
462
  goto st0;
462
463
  tr5:
463
- #line 317 "pitchfork_http.rl"
464
+ #line 318 "pitchfork_http.rl"
464
465
  {MARK(mark, p); }
465
466
  goto st4;
466
467
  st4:
467
468
  if ( ++p == pe )
468
469
  goto _test_eof4;
469
470
  case 4:
470
- #line 471 "pitchfork_http.c"
471
+ #line 472 "pitchfork_http.c"
471
472
  switch( (*p) ) {
472
473
  case 32: goto tr8;
473
474
  case 35: goto tr9;
474
475
  }
475
476
  goto st0;
476
477
  tr8:
477
- #line 331 "pitchfork_http.rl"
478
+ #line 332 "pitchfork_http.rl"
478
479
  {
479
480
  VALUE str;
480
481
 
@@ -492,23 +493,23 @@ tr8:
492
493
  }
493
494
  goto st5;
494
495
  tr42:
495
- #line 317 "pitchfork_http.rl"
496
+ #line 318 "pitchfork_http.rl"
496
497
  {MARK(mark, p); }
497
- #line 346 "pitchfork_http.rl"
498
+ #line 347 "pitchfork_http.rl"
498
499
  {
499
500
  VALIDATE_MAX_URI_LENGTH(LEN(mark, p), FRAGMENT);
500
501
  rb_hash_aset(hp->env, g_fragment, STR_NEW(mark, p));
501
502
  }
502
503
  goto st5;
503
504
  tr45:
504
- #line 346 "pitchfork_http.rl"
505
+ #line 347 "pitchfork_http.rl"
505
506
  {
506
507
  VALIDATE_MAX_URI_LENGTH(LEN(mark, p), FRAGMENT);
507
508
  rb_hash_aset(hp->env, g_fragment, STR_NEW(mark, p));
508
509
  }
509
510
  goto st5;
510
511
  tr49:
511
- #line 356 "pitchfork_http.rl"
512
+ #line 357 "pitchfork_http.rl"
512
513
  {
513
514
  VALUE val;
514
515
 
@@ -519,7 +520,7 @@ tr49:
519
520
  if (!STR_CSTR_EQ(val, "*"))
520
521
  rb_hash_aset(hp->env, g_path_info, val);
521
522
  }
522
- #line 331 "pitchfork_http.rl"
523
+ #line 332 "pitchfork_http.rl"
523
524
  {
524
525
  VALUE str;
525
526
 
@@ -537,14 +538,14 @@ tr49:
537
538
  }
538
539
  goto st5;
539
540
  tr55:
540
- #line 350 "pitchfork_http.rl"
541
- {MARK(start.query, p); }
542
541
  #line 351 "pitchfork_http.rl"
542
+ {MARK(start.query, p); }
543
+ #line 352 "pitchfork_http.rl"
543
544
  {
544
545
  VALIDATE_MAX_URI_LENGTH(LEN(start.query, p), QUERY_STRING);
545
546
  rb_hash_aset(hp->env, g_query_string, STR_NEW(start.query, p));
546
547
  }
547
- #line 331 "pitchfork_http.rl"
548
+ #line 332 "pitchfork_http.rl"
548
549
  {
549
550
  VALUE str;
550
551
 
@@ -562,12 +563,12 @@ tr55:
562
563
  }
563
564
  goto st5;
564
565
  tr59:
565
- #line 351 "pitchfork_http.rl"
566
+ #line 352 "pitchfork_http.rl"
566
567
  {
567
568
  VALIDATE_MAX_URI_LENGTH(LEN(start.query, p), QUERY_STRING);
568
569
  rb_hash_aset(hp->env, g_query_string, STR_NEW(start.query, p));
569
570
  }
570
- #line 331 "pitchfork_http.rl"
571
+ #line 332 "pitchfork_http.rl"
571
572
  {
572
573
  VALUE str;
573
574
 
@@ -588,19 +589,19 @@ st5:
588
589
  if ( ++p == pe )
589
590
  goto _test_eof5;
590
591
  case 5:
591
- #line 592 "pitchfork_http.c"
592
+ #line 593 "pitchfork_http.c"
592
593
  if ( (*p) == 72 )
593
594
  goto tr10;
594
595
  goto st0;
595
596
  tr10:
596
- #line 317 "pitchfork_http.rl"
597
+ #line 318 "pitchfork_http.rl"
597
598
  {MARK(mark, p); }
598
599
  goto st6;
599
600
  st6:
600
601
  if ( ++p == pe )
601
602
  goto _test_eof6;
602
603
  case 6:
603
- #line 604 "pitchfork_http.c"
604
+ #line 605 "pitchfork_http.c"
604
605
  if ( (*p) == 84 )
605
606
  goto st7;
606
607
  goto st0;
@@ -660,34 +661,34 @@ case 13:
660
661
  goto st13;
661
662
  goto st0;
662
663
  tr18:
663
- #line 355 "pitchfork_http.rl"
664
+ #line 356 "pitchfork_http.rl"
664
665
  { http_version(hp, PTR_TO(mark), LEN(mark, p)); }
665
666
  goto st14;
666
667
  tr26:
667
- #line 323 "pitchfork_http.rl"
668
+ #line 324 "pitchfork_http.rl"
668
669
  { MARK(mark, p); }
669
- #line 325 "pitchfork_http.rl"
670
+ #line 326 "pitchfork_http.rl"
670
671
  { write_cont_value(hp, buffer, p); }
671
672
  goto st14;
672
673
  tr29:
673
- #line 325 "pitchfork_http.rl"
674
+ #line 326 "pitchfork_http.rl"
674
675
  { write_cont_value(hp, buffer, p); }
675
676
  goto st14;
676
677
  tr36:
677
- #line 323 "pitchfork_http.rl"
678
- { MARK(mark, p); }
679
678
  #line 324 "pitchfork_http.rl"
679
+ { MARK(mark, p); }
680
+ #line 325 "pitchfork_http.rl"
680
681
  { write_value(self, hp, buffer, p); }
681
682
  goto st14;
682
683
  tr39:
683
- #line 324 "pitchfork_http.rl"
684
+ #line 325 "pitchfork_http.rl"
684
685
  { write_value(self, hp, buffer, p); }
685
686
  goto st14;
686
687
  st14:
687
688
  if ( ++p == pe )
688
689
  goto _test_eof14;
689
690
  case 14:
690
- #line 691 "pitchfork_http.c"
691
+ #line 692 "pitchfork_http.c"
691
692
  switch( (*p) ) {
692
693
  case 9: goto st15;
693
694
  case 10: goto tr21;
@@ -716,14 +717,14 @@ case 14:
716
717
  goto tr23;
717
718
  goto st0;
718
719
  tr25:
719
- #line 323 "pitchfork_http.rl"
720
+ #line 324 "pitchfork_http.rl"
720
721
  { MARK(mark, p); }
721
722
  goto st15;
722
723
  st15:
723
724
  if ( ++p == pe )
724
725
  goto _test_eof15;
725
726
  case 15:
726
- #line 727 "pitchfork_http.c"
727
+ #line 728 "pitchfork_http.c"
727
728
  switch( (*p) ) {
728
729
  case 9: goto tr25;
729
730
  case 10: goto tr26;
@@ -735,14 +736,14 @@ case 15:
735
736
  goto st0;
736
737
  goto tr24;
737
738
  tr24:
738
- #line 323 "pitchfork_http.rl"
739
+ #line 324 "pitchfork_http.rl"
739
740
  { MARK(mark, p); }
740
741
  goto st16;
741
742
  st16:
742
743
  if ( ++p == pe )
743
744
  goto _test_eof16;
744
745
  case 16:
745
- #line 746 "pitchfork_http.c"
746
+ #line 747 "pitchfork_http.c"
746
747
  switch( (*p) ) {
747
748
  case 10: goto tr29;
748
749
  case 13: goto tr30;
@@ -755,39 +756,39 @@ case 16:
755
756
  goto st0;
756
757
  goto st16;
757
758
  tr19:
758
- #line 355 "pitchfork_http.rl"
759
+ #line 356 "pitchfork_http.rl"
759
760
  { http_version(hp, PTR_TO(mark), LEN(mark, p)); }
760
761
  goto st17;
761
762
  tr27:
762
- #line 323 "pitchfork_http.rl"
763
+ #line 324 "pitchfork_http.rl"
763
764
  { MARK(mark, p); }
764
- #line 325 "pitchfork_http.rl"
765
+ #line 326 "pitchfork_http.rl"
765
766
  { write_cont_value(hp, buffer, p); }
766
767
  goto st17;
767
768
  tr30:
768
- #line 325 "pitchfork_http.rl"
769
+ #line 326 "pitchfork_http.rl"
769
770
  { write_cont_value(hp, buffer, p); }
770
771
  goto st17;
771
772
  tr37:
772
- #line 323 "pitchfork_http.rl"
773
- { MARK(mark, p); }
774
773
  #line 324 "pitchfork_http.rl"
774
+ { MARK(mark, p); }
775
+ #line 325 "pitchfork_http.rl"
775
776
  { write_value(self, hp, buffer, p); }
776
777
  goto st17;
777
778
  tr40:
778
- #line 324 "pitchfork_http.rl"
779
+ #line 325 "pitchfork_http.rl"
779
780
  { write_value(self, hp, buffer, p); }
780
781
  goto st17;
781
782
  st17:
782
783
  if ( ++p == pe )
783
784
  goto _test_eof17;
784
785
  case 17:
785
- #line 786 "pitchfork_http.c"
786
+ #line 787 "pitchfork_http.c"
786
787
  if ( (*p) == 10 )
787
788
  goto st14;
788
789
  goto st0;
789
790
  tr21:
790
- #line 371 "pitchfork_http.rl"
791
+ #line 372 "pitchfork_http.rl"
791
792
  {
792
793
  finalize_header(hp);
793
794
 
@@ -808,7 +809,7 @@ tr21:
808
809
  }
809
810
  goto st122;
810
811
  tr104:
811
- #line 331 "pitchfork_http.rl"
812
+ #line 332 "pitchfork_http.rl"
812
813
  {
813
814
  VALUE str;
814
815
 
@@ -824,7 +825,7 @@ tr104:
824
825
  rb_hash_aset(hp->env, g_request_path, str);
825
826
  }
826
827
  }
827
- #line 371 "pitchfork_http.rl"
828
+ #line 372 "pitchfork_http.rl"
828
829
  {
829
830
  finalize_header(hp);
830
831
 
@@ -845,14 +846,14 @@ tr104:
845
846
  }
846
847
  goto st122;
847
848
  tr108:
848
- #line 317 "pitchfork_http.rl"
849
+ #line 318 "pitchfork_http.rl"
849
850
  {MARK(mark, p); }
850
- #line 346 "pitchfork_http.rl"
851
+ #line 347 "pitchfork_http.rl"
851
852
  {
852
853
  VALIDATE_MAX_URI_LENGTH(LEN(mark, p), FRAGMENT);
853
854
  rb_hash_aset(hp->env, g_fragment, STR_NEW(mark, p));
854
855
  }
855
- #line 371 "pitchfork_http.rl"
856
+ #line 372 "pitchfork_http.rl"
856
857
  {
857
858
  finalize_header(hp);
858
859
 
@@ -873,12 +874,12 @@ tr108:
873
874
  }
874
875
  goto st122;
875
876
  tr112:
876
- #line 346 "pitchfork_http.rl"
877
+ #line 347 "pitchfork_http.rl"
877
878
  {
878
879
  VALIDATE_MAX_URI_LENGTH(LEN(mark, p), FRAGMENT);
879
880
  rb_hash_aset(hp->env, g_fragment, STR_NEW(mark, p));
880
881
  }
881
- #line 371 "pitchfork_http.rl"
882
+ #line 372 "pitchfork_http.rl"
882
883
  {
883
884
  finalize_header(hp);
884
885
 
@@ -899,7 +900,7 @@ tr112:
899
900
  }
900
901
  goto st122;
901
902
  tr117:
902
- #line 356 "pitchfork_http.rl"
903
+ #line 357 "pitchfork_http.rl"
903
904
  {
904
905
  VALUE val;
905
906
 
@@ -910,7 +911,7 @@ tr117:
910
911
  if (!STR_CSTR_EQ(val, "*"))
911
912
  rb_hash_aset(hp->env, g_path_info, val);
912
913
  }
913
- #line 331 "pitchfork_http.rl"
914
+ #line 332 "pitchfork_http.rl"
914
915
  {
915
916
  VALUE str;
916
917
 
@@ -926,7 +927,7 @@ tr117:
926
927
  rb_hash_aset(hp->env, g_request_path, str);
927
928
  }
928
929
  }
929
- #line 371 "pitchfork_http.rl"
930
+ #line 372 "pitchfork_http.rl"
930
931
  {
931
932
  finalize_header(hp);
932
933
 
@@ -947,14 +948,14 @@ tr117:
947
948
  }
948
949
  goto st122;
949
950
  tr124:
950
- #line 350 "pitchfork_http.rl"
951
- {MARK(start.query, p); }
952
951
  #line 351 "pitchfork_http.rl"
952
+ {MARK(start.query, p); }
953
+ #line 352 "pitchfork_http.rl"
953
954
  {
954
955
  VALIDATE_MAX_URI_LENGTH(LEN(start.query, p), QUERY_STRING);
955
956
  rb_hash_aset(hp->env, g_query_string, STR_NEW(start.query, p));
956
957
  }
957
- #line 331 "pitchfork_http.rl"
958
+ #line 332 "pitchfork_http.rl"
958
959
  {
959
960
  VALUE str;
960
961
 
@@ -970,7 +971,7 @@ tr124:
970
971
  rb_hash_aset(hp->env, g_request_path, str);
971
972
  }
972
973
  }
973
- #line 371 "pitchfork_http.rl"
974
+ #line 372 "pitchfork_http.rl"
974
975
  {
975
976
  finalize_header(hp);
976
977
 
@@ -991,12 +992,12 @@ tr124:
991
992
  }
992
993
  goto st122;
993
994
  tr129:
994
- #line 351 "pitchfork_http.rl"
995
+ #line 352 "pitchfork_http.rl"
995
996
  {
996
997
  VALIDATE_MAX_URI_LENGTH(LEN(start.query, p), QUERY_STRING);
997
998
  rb_hash_aset(hp->env, g_query_string, STR_NEW(start.query, p));
998
999
  }
999
- #line 331 "pitchfork_http.rl"
1000
+ #line 332 "pitchfork_http.rl"
1000
1001
  {
1001
1002
  VALUE str;
1002
1003
 
@@ -1012,7 +1013,7 @@ tr129:
1012
1013
  rb_hash_aset(hp->env, g_request_path, str);
1013
1014
  }
1014
1015
  }
1015
- #line 371 "pitchfork_http.rl"
1016
+ #line 372 "pitchfork_http.rl"
1016
1017
  {
1017
1018
  finalize_header(hp);
1018
1019
 
@@ -1036,10 +1037,10 @@ st122:
1036
1037
  if ( ++p == pe )
1037
1038
  goto _test_eof122;
1038
1039
  case 122:
1039
- #line 1040 "pitchfork_http.c"
1040
+ #line 1041 "pitchfork_http.c"
1040
1041
  goto st0;
1041
1042
  tr105:
1042
- #line 331 "pitchfork_http.rl"
1043
+ #line 332 "pitchfork_http.rl"
1043
1044
  {
1044
1045
  VALUE str;
1045
1046
 
@@ -1057,23 +1058,23 @@ tr105:
1057
1058
  }
1058
1059
  goto st18;
1059
1060
  tr109:
1060
- #line 317 "pitchfork_http.rl"
1061
+ #line 318 "pitchfork_http.rl"
1061
1062
  {MARK(mark, p); }
1062
- #line 346 "pitchfork_http.rl"
1063
+ #line 347 "pitchfork_http.rl"
1063
1064
  {
1064
1065
  VALIDATE_MAX_URI_LENGTH(LEN(mark, p), FRAGMENT);
1065
1066
  rb_hash_aset(hp->env, g_fragment, STR_NEW(mark, p));
1066
1067
  }
1067
1068
  goto st18;
1068
1069
  tr113:
1069
- #line 346 "pitchfork_http.rl"
1070
+ #line 347 "pitchfork_http.rl"
1070
1071
  {
1071
1072
  VALIDATE_MAX_URI_LENGTH(LEN(mark, p), FRAGMENT);
1072
1073
  rb_hash_aset(hp->env, g_fragment, STR_NEW(mark, p));
1073
1074
  }
1074
1075
  goto st18;
1075
1076
  tr118:
1076
- #line 356 "pitchfork_http.rl"
1077
+ #line 357 "pitchfork_http.rl"
1077
1078
  {
1078
1079
  VALUE val;
1079
1080
 
@@ -1084,7 +1085,7 @@ tr118:
1084
1085
  if (!STR_CSTR_EQ(val, "*"))
1085
1086
  rb_hash_aset(hp->env, g_path_info, val);
1086
1087
  }
1087
- #line 331 "pitchfork_http.rl"
1088
+ #line 332 "pitchfork_http.rl"
1088
1089
  {
1089
1090
  VALUE str;
1090
1091
 
@@ -1102,14 +1103,14 @@ tr118:
1102
1103
  }
1103
1104
  goto st18;
1104
1105
  tr125:
1105
- #line 350 "pitchfork_http.rl"
1106
- {MARK(start.query, p); }
1107
1106
  #line 351 "pitchfork_http.rl"
1107
+ {MARK(start.query, p); }
1108
+ #line 352 "pitchfork_http.rl"
1108
1109
  {
1109
1110
  VALIDATE_MAX_URI_LENGTH(LEN(start.query, p), QUERY_STRING);
1110
1111
  rb_hash_aset(hp->env, g_query_string, STR_NEW(start.query, p));
1111
1112
  }
1112
- #line 331 "pitchfork_http.rl"
1113
+ #line 332 "pitchfork_http.rl"
1113
1114
  {
1114
1115
  VALUE str;
1115
1116
 
@@ -1127,12 +1128,12 @@ tr125:
1127
1128
  }
1128
1129
  goto st18;
1129
1130
  tr130:
1130
- #line 351 "pitchfork_http.rl"
1131
+ #line 352 "pitchfork_http.rl"
1131
1132
  {
1132
1133
  VALIDATE_MAX_URI_LENGTH(LEN(start.query, p), QUERY_STRING);
1133
1134
  rb_hash_aset(hp->env, g_query_string, STR_NEW(start.query, p));
1134
1135
  }
1135
- #line 331 "pitchfork_http.rl"
1136
+ #line 332 "pitchfork_http.rl"
1136
1137
  {
1137
1138
  VALUE str;
1138
1139
 
@@ -1153,25 +1154,25 @@ st18:
1153
1154
  if ( ++p == pe )
1154
1155
  goto _test_eof18;
1155
1156
  case 18:
1156
- #line 1157 "pitchfork_http.c"
1157
+ #line 1158 "pitchfork_http.c"
1157
1158
  if ( (*p) == 10 )
1158
1159
  goto tr21;
1159
1160
  goto st0;
1160
1161
  tr23:
1161
- #line 319 "pitchfork_http.rl"
1162
- { MARK(start.field, p); }
1163
1162
  #line 320 "pitchfork_http.rl"
1163
+ { MARK(start.field, p); }
1164
+ #line 321 "pitchfork_http.rl"
1164
1165
  { snake_upcase_char(deconst(p)); }
1165
1166
  goto st19;
1166
1167
  tr32:
1167
- #line 320 "pitchfork_http.rl"
1168
+ #line 321 "pitchfork_http.rl"
1168
1169
  { snake_upcase_char(deconst(p)); }
1169
1170
  goto st19;
1170
1171
  st19:
1171
1172
  if ( ++p == pe )
1172
1173
  goto _test_eof19;
1173
1174
  case 19:
1174
- #line 1175 "pitchfork_http.c"
1175
+ #line 1176 "pitchfork_http.c"
1175
1176
  switch( (*p) ) {
1176
1177
  case 33: goto tr32;
1177
1178
  case 58: goto tr33;
@@ -1197,18 +1198,18 @@ case 19:
1197
1198
  goto tr32;
1198
1199
  goto st0;
1199
1200
  tr35:
1200
- #line 323 "pitchfork_http.rl"
1201
+ #line 324 "pitchfork_http.rl"
1201
1202
  { MARK(mark, p); }
1202
1203
  goto st20;
1203
1204
  tr33:
1204
- #line 322 "pitchfork_http.rl"
1205
+ #line 323 "pitchfork_http.rl"
1205
1206
  { hp->s.field_len = LEN(start.field, p); }
1206
1207
  goto st20;
1207
1208
  st20:
1208
1209
  if ( ++p == pe )
1209
1210
  goto _test_eof20;
1210
1211
  case 20:
1211
- #line 1212 "pitchfork_http.c"
1212
+ #line 1213 "pitchfork_http.c"
1212
1213
  switch( (*p) ) {
1213
1214
  case 9: goto tr35;
1214
1215
  case 10: goto tr36;
@@ -1220,14 +1221,14 @@ case 20:
1220
1221
  goto st0;
1221
1222
  goto tr34;
1222
1223
  tr34:
1223
- #line 323 "pitchfork_http.rl"
1224
+ #line 324 "pitchfork_http.rl"
1224
1225
  { MARK(mark, p); }
1225
1226
  goto st21;
1226
1227
  st21:
1227
1228
  if ( ++p == pe )
1228
1229
  goto _test_eof21;
1229
1230
  case 21:
1230
- #line 1231 "pitchfork_http.c"
1231
+ #line 1232 "pitchfork_http.c"
1231
1232
  switch( (*p) ) {
1232
1233
  case 10: goto tr39;
1233
1234
  case 13: goto tr40;
@@ -1240,7 +1241,7 @@ case 21:
1240
1241
  goto st0;
1241
1242
  goto st21;
1242
1243
  tr9:
1243
- #line 331 "pitchfork_http.rl"
1244
+ #line 332 "pitchfork_http.rl"
1244
1245
  {
1245
1246
  VALUE str;
1246
1247
 
@@ -1258,7 +1259,7 @@ tr9:
1258
1259
  }
1259
1260
  goto st22;
1260
1261
  tr50:
1261
- #line 356 "pitchfork_http.rl"
1262
+ #line 357 "pitchfork_http.rl"
1262
1263
  {
1263
1264
  VALUE val;
1264
1265
 
@@ -1269,7 +1270,7 @@ tr50:
1269
1270
  if (!STR_CSTR_EQ(val, "*"))
1270
1271
  rb_hash_aset(hp->env, g_path_info, val);
1271
1272
  }
1272
- #line 331 "pitchfork_http.rl"
1273
+ #line 332 "pitchfork_http.rl"
1273
1274
  {
1274
1275
  VALUE str;
1275
1276
 
@@ -1287,14 +1288,14 @@ tr50:
1287
1288
  }
1288
1289
  goto st22;
1289
1290
  tr56:
1290
- #line 350 "pitchfork_http.rl"
1291
- {MARK(start.query, p); }
1292
1291
  #line 351 "pitchfork_http.rl"
1292
+ {MARK(start.query, p); }
1293
+ #line 352 "pitchfork_http.rl"
1293
1294
  {
1294
1295
  VALIDATE_MAX_URI_LENGTH(LEN(start.query, p), QUERY_STRING);
1295
1296
  rb_hash_aset(hp->env, g_query_string, STR_NEW(start.query, p));
1296
1297
  }
1297
- #line 331 "pitchfork_http.rl"
1298
+ #line 332 "pitchfork_http.rl"
1298
1299
  {
1299
1300
  VALUE str;
1300
1301
 
@@ -1312,12 +1313,12 @@ tr56:
1312
1313
  }
1313
1314
  goto st22;
1314
1315
  tr60:
1315
- #line 351 "pitchfork_http.rl"
1316
+ #line 352 "pitchfork_http.rl"
1316
1317
  {
1317
1318
  VALIDATE_MAX_URI_LENGTH(LEN(start.query, p), QUERY_STRING);
1318
1319
  rb_hash_aset(hp->env, g_query_string, STR_NEW(start.query, p));
1319
1320
  }
1320
- #line 331 "pitchfork_http.rl"
1321
+ #line 332 "pitchfork_http.rl"
1321
1322
  {
1322
1323
  VALUE str;
1323
1324
 
@@ -1338,7 +1339,7 @@ st22:
1338
1339
  if ( ++p == pe )
1339
1340
  goto _test_eof22;
1340
1341
  case 22:
1341
- #line 1342 "pitchfork_http.c"
1342
+ #line 1343 "pitchfork_http.c"
1342
1343
  switch( (*p) ) {
1343
1344
  case 32: goto tr42;
1344
1345
  case 35: goto st0;
@@ -1349,14 +1350,14 @@ case 22:
1349
1350
  goto st0;
1350
1351
  goto tr41;
1351
1352
  tr41:
1352
- #line 317 "pitchfork_http.rl"
1353
+ #line 318 "pitchfork_http.rl"
1353
1354
  {MARK(mark, p); }
1354
1355
  goto st23;
1355
1356
  st23:
1356
1357
  if ( ++p == pe )
1357
1358
  goto _test_eof23;
1358
1359
  case 23:
1359
- #line 1360 "pitchfork_http.c"
1360
+ #line 1361 "pitchfork_http.c"
1360
1361
  switch( (*p) ) {
1361
1362
  case 32: goto tr45;
1362
1363
  case 35: goto st0;
@@ -1367,14 +1368,14 @@ case 23:
1367
1368
  goto st0;
1368
1369
  goto st23;
1369
1370
  tr43:
1370
- #line 317 "pitchfork_http.rl"
1371
+ #line 318 "pitchfork_http.rl"
1371
1372
  {MARK(mark, p); }
1372
1373
  goto st24;
1373
1374
  st24:
1374
1375
  if ( ++p == pe )
1375
1376
  goto _test_eof24;
1376
1377
  case 24:
1377
- #line 1378 "pitchfork_http.c"
1378
+ #line 1379 "pitchfork_http.c"
1378
1379
  if ( (*p) < 65 ) {
1379
1380
  if ( 48 <= (*p) && (*p) <= 57 )
1380
1381
  goto st25;
@@ -1398,20 +1399,20 @@ case 25:
1398
1399
  goto st23;
1399
1400
  goto st0;
1400
1401
  tr6:
1401
- #line 317 "pitchfork_http.rl"
1402
+ #line 318 "pitchfork_http.rl"
1402
1403
  {MARK(mark, p); }
1403
1404
  goto st26;
1404
1405
  tr76:
1405
- #line 330 "pitchfork_http.rl"
1406
+ #line 331 "pitchfork_http.rl"
1406
1407
  { rb_hash_aset(hp->env, g_http_host, STR_NEW(mark, p)); }
1407
- #line 317 "pitchfork_http.rl"
1408
+ #line 318 "pitchfork_http.rl"
1408
1409
  {MARK(mark, p); }
1409
1410
  goto st26;
1410
1411
  st26:
1411
1412
  if ( ++p == pe )
1412
1413
  goto _test_eof26;
1413
1414
  case 26:
1414
- #line 1415 "pitchfork_http.c"
1415
+ #line 1416 "pitchfork_http.c"
1415
1416
  switch( (*p) ) {
1416
1417
  case 32: goto tr49;
1417
1418
  case 35: goto tr50;
@@ -1449,7 +1450,7 @@ case 28:
1449
1450
  goto st26;
1450
1451
  goto st0;
1451
1452
  tr52:
1452
- #line 356 "pitchfork_http.rl"
1453
+ #line 357 "pitchfork_http.rl"
1453
1454
  {
1454
1455
  VALUE val;
1455
1456
 
@@ -1465,7 +1466,7 @@ st29:
1465
1466
  if ( ++p == pe )
1466
1467
  goto _test_eof29;
1467
1468
  case 29:
1468
- #line 1469 "pitchfork_http.c"
1469
+ #line 1470 "pitchfork_http.c"
1469
1470
  switch( (*p) ) {
1470
1471
  case 32: goto tr55;
1471
1472
  case 35: goto tr56;
@@ -1476,14 +1477,14 @@ case 29:
1476
1477
  goto st0;
1477
1478
  goto tr54;
1478
1479
  tr54:
1479
- #line 350 "pitchfork_http.rl"
1480
+ #line 351 "pitchfork_http.rl"
1480
1481
  {MARK(start.query, p); }
1481
1482
  goto st30;
1482
1483
  st30:
1483
1484
  if ( ++p == pe )
1484
1485
  goto _test_eof30;
1485
1486
  case 30:
1486
- #line 1487 "pitchfork_http.c"
1487
+ #line 1488 "pitchfork_http.c"
1487
1488
  switch( (*p) ) {
1488
1489
  case 32: goto tr59;
1489
1490
  case 35: goto tr60;
@@ -1494,14 +1495,14 @@ case 30:
1494
1495
  goto st0;
1495
1496
  goto st30;
1496
1497
  tr57:
1497
- #line 350 "pitchfork_http.rl"
1498
+ #line 351 "pitchfork_http.rl"
1498
1499
  {MARK(start.query, p); }
1499
1500
  goto st31;
1500
1501
  st31:
1501
1502
  if ( ++p == pe )
1502
1503
  goto _test_eof31;
1503
1504
  case 31:
1504
- #line 1505 "pitchfork_http.c"
1505
+ #line 1506 "pitchfork_http.c"
1505
1506
  if ( (*p) < 65 ) {
1506
1507
  if ( 48 <= (*p) && (*p) <= 57 )
1507
1508
  goto st32;
@@ -1525,58 +1526,58 @@ case 32:
1525
1526
  goto st30;
1526
1527
  goto st0;
1527
1528
  tr7:
1528
- #line 317 "pitchfork_http.rl"
1529
+ #line 318 "pitchfork_http.rl"
1529
1530
  {MARK(mark, p); }
1530
- #line 321 "pitchfork_http.rl"
1531
+ #line 322 "pitchfork_http.rl"
1531
1532
  { downcase_char(deconst(p)); }
1532
1533
  goto st33;
1533
1534
  st33:
1534
1535
  if ( ++p == pe )
1535
1536
  goto _test_eof33;
1536
1537
  case 33:
1537
- #line 1538 "pitchfork_http.c"
1538
+ #line 1539 "pitchfork_http.c"
1538
1539
  switch( (*p) ) {
1539
1540
  case 84: goto tr63;
1540
1541
  case 116: goto tr63;
1541
1542
  }
1542
1543
  goto st0;
1543
1544
  tr63:
1544
- #line 321 "pitchfork_http.rl"
1545
+ #line 322 "pitchfork_http.rl"
1545
1546
  { downcase_char(deconst(p)); }
1546
1547
  goto st34;
1547
1548
  st34:
1548
1549
  if ( ++p == pe )
1549
1550
  goto _test_eof34;
1550
1551
  case 34:
1551
- #line 1552 "pitchfork_http.c"
1552
+ #line 1553 "pitchfork_http.c"
1552
1553
  switch( (*p) ) {
1553
1554
  case 84: goto tr64;
1554
1555
  case 116: goto tr64;
1555
1556
  }
1556
1557
  goto st0;
1557
1558
  tr64:
1558
- #line 321 "pitchfork_http.rl"
1559
+ #line 322 "pitchfork_http.rl"
1559
1560
  { downcase_char(deconst(p)); }
1560
1561
  goto st35;
1561
1562
  st35:
1562
1563
  if ( ++p == pe )
1563
1564
  goto _test_eof35;
1564
1565
  case 35:
1565
- #line 1566 "pitchfork_http.c"
1566
+ #line 1567 "pitchfork_http.c"
1566
1567
  switch( (*p) ) {
1567
1568
  case 80: goto tr65;
1568
1569
  case 112: goto tr65;
1569
1570
  }
1570
1571
  goto st0;
1571
1572
  tr65:
1572
- #line 321 "pitchfork_http.rl"
1573
+ #line 322 "pitchfork_http.rl"
1573
1574
  { downcase_char(deconst(p)); }
1574
1575
  goto st36;
1575
1576
  st36:
1576
1577
  if ( ++p == pe )
1577
1578
  goto _test_eof36;
1578
1579
  case 36:
1579
- #line 1580 "pitchfork_http.c"
1580
+ #line 1581 "pitchfork_http.c"
1580
1581
  switch( (*p) ) {
1581
1582
  case 58: goto tr66;
1582
1583
  case 83: goto tr67;
@@ -1584,7 +1585,7 @@ case 36:
1584
1585
  }
1585
1586
  goto st0;
1586
1587
  tr66:
1587
- #line 327 "pitchfork_http.rl"
1588
+ #line 328 "pitchfork_http.rl"
1588
1589
  {
1589
1590
  rb_hash_aset(hp->env, g_rack_url_scheme, STR_NEW(mark, p));
1590
1591
  }
@@ -1593,7 +1594,7 @@ st37:
1593
1594
  if ( ++p == pe )
1594
1595
  goto _test_eof37;
1595
1596
  case 37:
1596
- #line 1597 "pitchfork_http.c"
1597
+ #line 1598 "pitchfork_http.c"
1597
1598
  if ( (*p) == 47 )
1598
1599
  goto st38;
1599
1600
  goto st0;
@@ -1681,14 +1682,14 @@ case 42:
1681
1682
  goto st40;
1682
1683
  goto st0;
1683
1684
  tr72:
1684
- #line 317 "pitchfork_http.rl"
1685
+ #line 318 "pitchfork_http.rl"
1685
1686
  {MARK(mark, p); }
1686
1687
  goto st43;
1687
1688
  st43:
1688
1689
  if ( ++p == pe )
1689
1690
  goto _test_eof43;
1690
1691
  case 43:
1691
- #line 1692 "pitchfork_http.c"
1692
+ #line 1693 "pitchfork_http.c"
1692
1693
  switch( (*p) ) {
1693
1694
  case 37: goto st41;
1694
1695
  case 47: goto tr76;
@@ -1740,14 +1741,14 @@ case 44:
1740
1741
  goto st0;
1741
1742
  goto st40;
1742
1743
  tr73:
1743
- #line 317 "pitchfork_http.rl"
1744
+ #line 318 "pitchfork_http.rl"
1744
1745
  {MARK(mark, p); }
1745
1746
  goto st45;
1746
1747
  st45:
1747
1748
  if ( ++p == pe )
1748
1749
  goto _test_eof45;
1749
1750
  case 45:
1750
- #line 1751 "pitchfork_http.c"
1751
+ #line 1752 "pitchfork_http.c"
1751
1752
  switch( (*p) ) {
1752
1753
  case 37: goto st41;
1753
1754
  case 47: goto st0;
@@ -1825,14 +1826,14 @@ case 47:
1825
1826
  goto st0;
1826
1827
  goto st40;
1827
1828
  tr67:
1828
- #line 321 "pitchfork_http.rl"
1829
+ #line 322 "pitchfork_http.rl"
1829
1830
  { downcase_char(deconst(p)); }
1830
1831
  goto st48;
1831
1832
  st48:
1832
1833
  if ( ++p == pe )
1833
1834
  goto _test_eof48;
1834
1835
  case 48:
1835
- #line 1836 "pitchfork_http.c"
1836
+ #line 1837 "pitchfork_http.c"
1836
1837
  if ( (*p) == 58 )
1837
1838
  goto tr66;
1838
1839
  goto st0;
@@ -2348,14 +2349,14 @@ case 67:
2348
2349
  goto tr3;
2349
2350
  goto st0;
2350
2351
  tr2:
2351
- #line 317 "pitchfork_http.rl"
2352
+ #line 318 "pitchfork_http.rl"
2352
2353
  {MARK(mark, p); }
2353
2354
  goto st68;
2354
2355
  st68:
2355
2356
  if ( ++p == pe )
2356
2357
  goto _test_eof68;
2357
2358
  case 68:
2358
- #line 2359 "pitchfork_http.c"
2359
+ #line 2360 "pitchfork_http.c"
2359
2360
  switch( (*p) ) {
2360
2361
  case 32: goto tr3;
2361
2362
  case 33: goto st49;
@@ -2439,14 +2440,14 @@ case 70:
2439
2440
  goto st51;
2440
2441
  goto st0;
2441
2442
  tr100:
2442
- #line 326 "pitchfork_http.rl"
2443
+ #line 327 "pitchfork_http.rl"
2443
2444
  { request_method(hp, PTR_TO(mark), LEN(mark, p)); }
2444
2445
  goto st71;
2445
2446
  st71:
2446
2447
  if ( ++p == pe )
2447
2448
  goto _test_eof71;
2448
2449
  case 71:
2449
- #line 2450 "pitchfork_http.c"
2450
+ #line 2451 "pitchfork_http.c"
2450
2451
  switch( (*p) ) {
2451
2452
  case 42: goto tr101;
2452
2453
  case 47: goto tr102;
@@ -2455,14 +2456,14 @@ case 71:
2455
2456
  }
2456
2457
  goto st0;
2457
2458
  tr101:
2458
- #line 317 "pitchfork_http.rl"
2459
+ #line 318 "pitchfork_http.rl"
2459
2460
  {MARK(mark, p); }
2460
2461
  goto st72;
2461
2462
  st72:
2462
2463
  if ( ++p == pe )
2463
2464
  goto _test_eof72;
2464
2465
  case 72:
2465
- #line 2466 "pitchfork_http.c"
2466
+ #line 2467 "pitchfork_http.c"
2466
2467
  switch( (*p) ) {
2467
2468
  case 10: goto tr104;
2468
2469
  case 13: goto tr105;
@@ -2471,7 +2472,7 @@ case 72:
2471
2472
  }
2472
2473
  goto st0;
2473
2474
  tr106:
2474
- #line 331 "pitchfork_http.rl"
2475
+ #line 332 "pitchfork_http.rl"
2475
2476
  {
2476
2477
  VALUE str;
2477
2478
 
@@ -2489,7 +2490,7 @@ tr106:
2489
2490
  }
2490
2491
  goto st73;
2491
2492
  tr119:
2492
- #line 356 "pitchfork_http.rl"
2493
+ #line 357 "pitchfork_http.rl"
2493
2494
  {
2494
2495
  VALUE val;
2495
2496
 
@@ -2500,7 +2501,7 @@ tr119:
2500
2501
  if (!STR_CSTR_EQ(val, "*"))
2501
2502
  rb_hash_aset(hp->env, g_path_info, val);
2502
2503
  }
2503
- #line 331 "pitchfork_http.rl"
2504
+ #line 332 "pitchfork_http.rl"
2504
2505
  {
2505
2506
  VALUE str;
2506
2507
 
@@ -2518,14 +2519,14 @@ tr119:
2518
2519
  }
2519
2520
  goto st73;
2520
2521
  tr126:
2521
- #line 350 "pitchfork_http.rl"
2522
- {MARK(start.query, p); }
2523
2522
  #line 351 "pitchfork_http.rl"
2523
+ {MARK(start.query, p); }
2524
+ #line 352 "pitchfork_http.rl"
2524
2525
  {
2525
2526
  VALIDATE_MAX_URI_LENGTH(LEN(start.query, p), QUERY_STRING);
2526
2527
  rb_hash_aset(hp->env, g_query_string, STR_NEW(start.query, p));
2527
2528
  }
2528
- #line 331 "pitchfork_http.rl"
2529
+ #line 332 "pitchfork_http.rl"
2529
2530
  {
2530
2531
  VALUE str;
2531
2532
 
@@ -2543,12 +2544,12 @@ tr126:
2543
2544
  }
2544
2545
  goto st73;
2545
2546
  tr131:
2546
- #line 351 "pitchfork_http.rl"
2547
+ #line 352 "pitchfork_http.rl"
2547
2548
  {
2548
2549
  VALIDATE_MAX_URI_LENGTH(LEN(start.query, p), QUERY_STRING);
2549
2550
  rb_hash_aset(hp->env, g_query_string, STR_NEW(start.query, p));
2550
2551
  }
2551
- #line 331 "pitchfork_http.rl"
2552
+ #line 332 "pitchfork_http.rl"
2552
2553
  {
2553
2554
  VALUE str;
2554
2555
 
@@ -2569,7 +2570,7 @@ st73:
2569
2570
  if ( ++p == pe )
2570
2571
  goto _test_eof73;
2571
2572
  case 73:
2572
- #line 2573 "pitchfork_http.c"
2573
+ #line 2574 "pitchfork_http.c"
2573
2574
  switch( (*p) ) {
2574
2575
  case 10: goto tr108;
2575
2576
  case 13: goto tr109;
@@ -2582,14 +2583,14 @@ case 73:
2582
2583
  goto st0;
2583
2584
  goto tr107;
2584
2585
  tr107:
2585
- #line 317 "pitchfork_http.rl"
2586
+ #line 318 "pitchfork_http.rl"
2586
2587
  {MARK(mark, p); }
2587
2588
  goto st74;
2588
2589
  st74:
2589
2590
  if ( ++p == pe )
2590
2591
  goto _test_eof74;
2591
2592
  case 74:
2592
- #line 2593 "pitchfork_http.c"
2593
+ #line 2594 "pitchfork_http.c"
2593
2594
  switch( (*p) ) {
2594
2595
  case 10: goto tr112;
2595
2596
  case 13: goto tr113;
@@ -2602,14 +2603,14 @@ case 74:
2602
2603
  goto st0;
2603
2604
  goto st74;
2604
2605
  tr110:
2605
- #line 317 "pitchfork_http.rl"
2606
+ #line 318 "pitchfork_http.rl"
2606
2607
  {MARK(mark, p); }
2607
2608
  goto st75;
2608
2609
  st75:
2609
2610
  if ( ++p == pe )
2610
2611
  goto _test_eof75;
2611
2612
  case 75:
2612
- #line 2613 "pitchfork_http.c"
2613
+ #line 2614 "pitchfork_http.c"
2613
2614
  if ( (*p) < 65 ) {
2614
2615
  if ( 48 <= (*p) && (*p) <= 57 )
2615
2616
  goto st76;
@@ -2633,20 +2634,20 @@ case 76:
2633
2634
  goto st74;
2634
2635
  goto st0;
2635
2636
  tr102:
2636
- #line 317 "pitchfork_http.rl"
2637
+ #line 318 "pitchfork_http.rl"
2637
2638
  {MARK(mark, p); }
2638
2639
  goto st77;
2639
2640
  tr147:
2640
- #line 330 "pitchfork_http.rl"
2641
+ #line 331 "pitchfork_http.rl"
2641
2642
  { rb_hash_aset(hp->env, g_http_host, STR_NEW(mark, p)); }
2642
- #line 317 "pitchfork_http.rl"
2643
+ #line 318 "pitchfork_http.rl"
2643
2644
  {MARK(mark, p); }
2644
2645
  goto st77;
2645
2646
  st77:
2646
2647
  if ( ++p == pe )
2647
2648
  goto _test_eof77;
2648
2649
  case 77:
2649
- #line 2650 "pitchfork_http.c"
2650
+ #line 2651 "pitchfork_http.c"
2650
2651
  switch( (*p) ) {
2651
2652
  case 10: goto tr117;
2652
2653
  case 13: goto tr118;
@@ -2686,7 +2687,7 @@ case 79:
2686
2687
  goto st77;
2687
2688
  goto st0;
2688
2689
  tr121:
2689
- #line 356 "pitchfork_http.rl"
2690
+ #line 357 "pitchfork_http.rl"
2690
2691
  {
2691
2692
  VALUE val;
2692
2693
 
@@ -2702,7 +2703,7 @@ st80:
2702
2703
  if ( ++p == pe )
2703
2704
  goto _test_eof80;
2704
2705
  case 80:
2705
- #line 2706 "pitchfork_http.c"
2706
+ #line 2707 "pitchfork_http.c"
2706
2707
  switch( (*p) ) {
2707
2708
  case 10: goto tr124;
2708
2709
  case 13: goto tr125;
@@ -2715,14 +2716,14 @@ case 80:
2715
2716
  goto st0;
2716
2717
  goto tr123;
2717
2718
  tr123:
2718
- #line 350 "pitchfork_http.rl"
2719
+ #line 351 "pitchfork_http.rl"
2719
2720
  {MARK(start.query, p); }
2720
2721
  goto st81;
2721
2722
  st81:
2722
2723
  if ( ++p == pe )
2723
2724
  goto _test_eof81;
2724
2725
  case 81:
2725
- #line 2726 "pitchfork_http.c"
2726
+ #line 2727 "pitchfork_http.c"
2726
2727
  switch( (*p) ) {
2727
2728
  case 10: goto tr129;
2728
2729
  case 13: goto tr130;
@@ -2735,14 +2736,14 @@ case 81:
2735
2736
  goto st0;
2736
2737
  goto st81;
2737
2738
  tr127:
2738
- #line 350 "pitchfork_http.rl"
2739
+ #line 351 "pitchfork_http.rl"
2739
2740
  {MARK(start.query, p); }
2740
2741
  goto st82;
2741
2742
  st82:
2742
2743
  if ( ++p == pe )
2743
2744
  goto _test_eof82;
2744
2745
  case 82:
2745
- #line 2746 "pitchfork_http.c"
2746
+ #line 2747 "pitchfork_http.c"
2746
2747
  if ( (*p) < 65 ) {
2747
2748
  if ( 48 <= (*p) && (*p) <= 57 )
2748
2749
  goto st83;
@@ -2766,58 +2767,58 @@ case 83:
2766
2767
  goto st81;
2767
2768
  goto st0;
2768
2769
  tr103:
2769
- #line 317 "pitchfork_http.rl"
2770
+ #line 318 "pitchfork_http.rl"
2770
2771
  {MARK(mark, p); }
2771
- #line 321 "pitchfork_http.rl"
2772
+ #line 322 "pitchfork_http.rl"
2772
2773
  { downcase_char(deconst(p)); }
2773
2774
  goto st84;
2774
2775
  st84:
2775
2776
  if ( ++p == pe )
2776
2777
  goto _test_eof84;
2777
2778
  case 84:
2778
- #line 2779 "pitchfork_http.c"
2779
+ #line 2780 "pitchfork_http.c"
2779
2780
  switch( (*p) ) {
2780
2781
  case 84: goto tr134;
2781
2782
  case 116: goto tr134;
2782
2783
  }
2783
2784
  goto st0;
2784
2785
  tr134:
2785
- #line 321 "pitchfork_http.rl"
2786
+ #line 322 "pitchfork_http.rl"
2786
2787
  { downcase_char(deconst(p)); }
2787
2788
  goto st85;
2788
2789
  st85:
2789
2790
  if ( ++p == pe )
2790
2791
  goto _test_eof85;
2791
2792
  case 85:
2792
- #line 2793 "pitchfork_http.c"
2793
+ #line 2794 "pitchfork_http.c"
2793
2794
  switch( (*p) ) {
2794
2795
  case 84: goto tr135;
2795
2796
  case 116: goto tr135;
2796
2797
  }
2797
2798
  goto st0;
2798
2799
  tr135:
2799
- #line 321 "pitchfork_http.rl"
2800
+ #line 322 "pitchfork_http.rl"
2800
2801
  { downcase_char(deconst(p)); }
2801
2802
  goto st86;
2802
2803
  st86:
2803
2804
  if ( ++p == pe )
2804
2805
  goto _test_eof86;
2805
2806
  case 86:
2806
- #line 2807 "pitchfork_http.c"
2807
+ #line 2808 "pitchfork_http.c"
2807
2808
  switch( (*p) ) {
2808
2809
  case 80: goto tr136;
2809
2810
  case 112: goto tr136;
2810
2811
  }
2811
2812
  goto st0;
2812
2813
  tr136:
2813
- #line 321 "pitchfork_http.rl"
2814
+ #line 322 "pitchfork_http.rl"
2814
2815
  { downcase_char(deconst(p)); }
2815
2816
  goto st87;
2816
2817
  st87:
2817
2818
  if ( ++p == pe )
2818
2819
  goto _test_eof87;
2819
2820
  case 87:
2820
- #line 2821 "pitchfork_http.c"
2821
+ #line 2822 "pitchfork_http.c"
2821
2822
  switch( (*p) ) {
2822
2823
  case 58: goto tr137;
2823
2824
  case 83: goto tr138;
@@ -2825,7 +2826,7 @@ case 87:
2825
2826
  }
2826
2827
  goto st0;
2827
2828
  tr137:
2828
- #line 327 "pitchfork_http.rl"
2829
+ #line 328 "pitchfork_http.rl"
2829
2830
  {
2830
2831
  rb_hash_aset(hp->env, g_rack_url_scheme, STR_NEW(mark, p));
2831
2832
  }
@@ -2834,7 +2835,7 @@ st88:
2834
2835
  if ( ++p == pe )
2835
2836
  goto _test_eof88;
2836
2837
  case 88:
2837
- #line 2838 "pitchfork_http.c"
2838
+ #line 2839 "pitchfork_http.c"
2838
2839
  if ( (*p) == 47 )
2839
2840
  goto st89;
2840
2841
  goto st0;
@@ -2922,14 +2923,14 @@ case 93:
2922
2923
  goto st91;
2923
2924
  goto st0;
2924
2925
  tr143:
2925
- #line 317 "pitchfork_http.rl"
2926
+ #line 318 "pitchfork_http.rl"
2926
2927
  {MARK(mark, p); }
2927
2928
  goto st94;
2928
2929
  st94:
2929
2930
  if ( ++p == pe )
2930
2931
  goto _test_eof94;
2931
2932
  case 94:
2932
- #line 2933 "pitchfork_http.c"
2933
+ #line 2934 "pitchfork_http.c"
2933
2934
  switch( (*p) ) {
2934
2935
  case 37: goto st92;
2935
2936
  case 47: goto tr147;
@@ -2981,14 +2982,14 @@ case 95:
2981
2982
  goto st0;
2982
2983
  goto st91;
2983
2984
  tr144:
2984
- #line 317 "pitchfork_http.rl"
2985
+ #line 318 "pitchfork_http.rl"
2985
2986
  {MARK(mark, p); }
2986
2987
  goto st96;
2987
2988
  st96:
2988
2989
  if ( ++p == pe )
2989
2990
  goto _test_eof96;
2990
2991
  case 96:
2991
- #line 2992 "pitchfork_http.c"
2992
+ #line 2993 "pitchfork_http.c"
2992
2993
  switch( (*p) ) {
2993
2994
  case 37: goto st92;
2994
2995
  case 47: goto st0;
@@ -3066,14 +3067,14 @@ case 98:
3066
3067
  goto st0;
3067
3068
  goto st91;
3068
3069
  tr138:
3069
- #line 321 "pitchfork_http.rl"
3070
+ #line 322 "pitchfork_http.rl"
3070
3071
  { downcase_char(deconst(p)); }
3071
3072
  goto st99;
3072
3073
  st99:
3073
3074
  if ( ++p == pe )
3074
3075
  goto _test_eof99;
3075
3076
  case 99:
3076
- #line 3077 "pitchfork_http.c"
3077
+ #line 3078 "pitchfork_http.c"
3077
3078
  if ( (*p) == 58 )
3078
3079
  goto tr137;
3079
3080
  goto st0;
@@ -3093,7 +3094,7 @@ case 100:
3093
3094
  goto tr152;
3094
3095
  goto st0;
3095
3096
  tr151:
3096
- #line 366 "pitchfork_http.rl"
3097
+ #line 367 "pitchfork_http.rl"
3097
3098
  {
3098
3099
  hp->len.chunk = step_incr(hp->len.chunk, (*p), 16);
3099
3100
  if (hp->len.chunk < 0)
@@ -3104,7 +3105,7 @@ st101:
3104
3105
  if ( ++p == pe )
3105
3106
  goto _test_eof101;
3106
3107
  case 101:
3107
- #line 3108 "pitchfork_http.c"
3108
+ #line 3109 "pitchfork_http.c"
3108
3109
  switch( (*p) ) {
3109
3110
  case 10: goto tr153;
3110
3111
  case 13: goto st102;
@@ -3121,7 +3122,7 @@ case 101:
3121
3122
  goto tr152;
3122
3123
  goto st0;
3123
3124
  tr153:
3124
- #line 395 "pitchfork_http.rl"
3125
+ #line 396 "pitchfork_http.rl"
3125
3126
  {
3126
3127
  HP_FL_SET(hp, INTRAILER);
3127
3128
  cs = http_parser_en_Trailers;
@@ -3134,7 +3135,7 @@ st123:
3134
3135
  if ( ++p == pe )
3135
3136
  goto _test_eof123;
3136
3137
  case 123:
3137
- #line 3138 "pitchfork_http.c"
3138
+ #line 3139 "pitchfork_http.c"
3138
3139
  goto st0;
3139
3140
  st102:
3140
3141
  if ( ++p == pe )
@@ -3144,7 +3145,7 @@ case 102:
3144
3145
  goto tr153;
3145
3146
  goto st0;
3146
3147
  tr152:
3147
- #line 366 "pitchfork_http.rl"
3148
+ #line 367 "pitchfork_http.rl"
3148
3149
  {
3149
3150
  hp->len.chunk = step_incr(hp->len.chunk, (*p), 16);
3150
3151
  if (hp->len.chunk < 0)
@@ -3155,7 +3156,7 @@ st103:
3155
3156
  if ( ++p == pe )
3156
3157
  goto _test_eof103;
3157
3158
  case 103:
3158
- #line 3159 "pitchfork_http.c"
3159
+ #line 3160 "pitchfork_http.c"
3159
3160
  switch( (*p) ) {
3160
3161
  case 10: goto st104;
3161
3162
  case 13: goto st107;
@@ -3176,7 +3177,7 @@ st104:
3176
3177
  case 104:
3177
3178
  goto tr159;
3178
3179
  tr159:
3179
- #line 403 "pitchfork_http.rl"
3180
+ #line 404 "pitchfork_http.rl"
3180
3181
  {
3181
3182
  skip_chunk_data_hack: {
3182
3183
  size_t nr = MIN((size_t)hp->len.chunk, REMAINING);
@@ -3198,7 +3199,7 @@ st105:
3198
3199
  if ( ++p == pe )
3199
3200
  goto _test_eof105;
3200
3201
  case 105:
3201
- #line 3202 "pitchfork_http.c"
3202
+ #line 3203 "pitchfork_http.c"
3202
3203
  switch( (*p) ) {
3203
3204
  case 10: goto st100;
3204
3205
  case 13: goto st106;
@@ -3405,30 +3406,30 @@ case 113:
3405
3406
  goto st113;
3406
3407
  goto st0;
3407
3408
  tr172:
3408
- #line 323 "pitchfork_http.rl"
3409
+ #line 324 "pitchfork_http.rl"
3409
3410
  { MARK(mark, p); }
3410
- #line 325 "pitchfork_http.rl"
3411
+ #line 326 "pitchfork_http.rl"
3411
3412
  { write_cont_value(hp, buffer, p); }
3412
3413
  goto st114;
3413
3414
  tr175:
3414
- #line 325 "pitchfork_http.rl"
3415
+ #line 326 "pitchfork_http.rl"
3415
3416
  { write_cont_value(hp, buffer, p); }
3416
3417
  goto st114;
3417
3418
  tr182:
3418
- #line 323 "pitchfork_http.rl"
3419
- { MARK(mark, p); }
3420
3419
  #line 324 "pitchfork_http.rl"
3420
+ { MARK(mark, p); }
3421
+ #line 325 "pitchfork_http.rl"
3421
3422
  { write_value(self, hp, buffer, p); }
3422
3423
  goto st114;
3423
3424
  tr185:
3424
- #line 324 "pitchfork_http.rl"
3425
+ #line 325 "pitchfork_http.rl"
3425
3426
  { write_value(self, hp, buffer, p); }
3426
3427
  goto st114;
3427
3428
  st114:
3428
3429
  if ( ++p == pe )
3429
3430
  goto _test_eof114;
3430
3431
  case 114:
3431
- #line 3432 "pitchfork_http.c"
3432
+ #line 3433 "pitchfork_http.c"
3432
3433
  switch( (*p) ) {
3433
3434
  case 9: goto st115;
3434
3435
  case 10: goto tr167;
@@ -3457,14 +3458,14 @@ case 114:
3457
3458
  goto tr169;
3458
3459
  goto st0;
3459
3460
  tr171:
3460
- #line 323 "pitchfork_http.rl"
3461
+ #line 324 "pitchfork_http.rl"
3461
3462
  { MARK(mark, p); }
3462
3463
  goto st115;
3463
3464
  st115:
3464
3465
  if ( ++p == pe )
3465
3466
  goto _test_eof115;
3466
3467
  case 115:
3467
- #line 3468 "pitchfork_http.c"
3468
+ #line 3469 "pitchfork_http.c"
3468
3469
  switch( (*p) ) {
3469
3470
  case 9: goto tr171;
3470
3471
  case 10: goto tr172;
@@ -3476,14 +3477,14 @@ case 115:
3476
3477
  goto st0;
3477
3478
  goto tr170;
3478
3479
  tr170:
3479
- #line 323 "pitchfork_http.rl"
3480
+ #line 324 "pitchfork_http.rl"
3480
3481
  { MARK(mark, p); }
3481
3482
  goto st116;
3482
3483
  st116:
3483
3484
  if ( ++p == pe )
3484
3485
  goto _test_eof116;
3485
3486
  case 116:
3486
- #line 3487 "pitchfork_http.c"
3487
+ #line 3488 "pitchfork_http.c"
3487
3488
  switch( (*p) ) {
3488
3489
  case 10: goto tr175;
3489
3490
  case 13: goto tr176;
@@ -3496,35 +3497,35 @@ case 116:
3496
3497
  goto st0;
3497
3498
  goto st116;
3498
3499
  tr173:
3499
- #line 323 "pitchfork_http.rl"
3500
+ #line 324 "pitchfork_http.rl"
3500
3501
  { MARK(mark, p); }
3501
- #line 325 "pitchfork_http.rl"
3502
+ #line 326 "pitchfork_http.rl"
3502
3503
  { write_cont_value(hp, buffer, p); }
3503
3504
  goto st117;
3504
3505
  tr176:
3505
- #line 325 "pitchfork_http.rl"
3506
+ #line 326 "pitchfork_http.rl"
3506
3507
  { write_cont_value(hp, buffer, p); }
3507
3508
  goto st117;
3508
3509
  tr183:
3509
- #line 323 "pitchfork_http.rl"
3510
- { MARK(mark, p); }
3511
3510
  #line 324 "pitchfork_http.rl"
3511
+ { MARK(mark, p); }
3512
+ #line 325 "pitchfork_http.rl"
3512
3513
  { write_value(self, hp, buffer, p); }
3513
3514
  goto st117;
3514
3515
  tr186:
3515
- #line 324 "pitchfork_http.rl"
3516
+ #line 325 "pitchfork_http.rl"
3516
3517
  { write_value(self, hp, buffer, p); }
3517
3518
  goto st117;
3518
3519
  st117:
3519
3520
  if ( ++p == pe )
3520
3521
  goto _test_eof117;
3521
3522
  case 117:
3522
- #line 3523 "pitchfork_http.c"
3523
+ #line 3524 "pitchfork_http.c"
3523
3524
  if ( (*p) == 10 )
3524
3525
  goto st114;
3525
3526
  goto st0;
3526
3527
  tr167:
3527
- #line 390 "pitchfork_http.rl"
3528
+ #line 391 "pitchfork_http.rl"
3528
3529
  {
3529
3530
  cs = http_parser_first_final;
3530
3531
  goto post_exec;
@@ -3534,7 +3535,7 @@ st124:
3534
3535
  if ( ++p == pe )
3535
3536
  goto _test_eof124;
3536
3537
  case 124:
3537
- #line 3538 "pitchfork_http.c"
3538
+ #line 3539 "pitchfork_http.c"
3538
3539
  goto st0;
3539
3540
  st118:
3540
3541
  if ( ++p == pe )
@@ -3544,20 +3545,20 @@ case 118:
3544
3545
  goto tr167;
3545
3546
  goto st0;
3546
3547
  tr169:
3547
- #line 319 "pitchfork_http.rl"
3548
- { MARK(start.field, p); }
3549
3548
  #line 320 "pitchfork_http.rl"
3549
+ { MARK(start.field, p); }
3550
+ #line 321 "pitchfork_http.rl"
3550
3551
  { snake_upcase_char(deconst(p)); }
3551
3552
  goto st119;
3552
3553
  tr178:
3553
- #line 320 "pitchfork_http.rl"
3554
+ #line 321 "pitchfork_http.rl"
3554
3555
  { snake_upcase_char(deconst(p)); }
3555
3556
  goto st119;
3556
3557
  st119:
3557
3558
  if ( ++p == pe )
3558
3559
  goto _test_eof119;
3559
3560
  case 119:
3560
- #line 3561 "pitchfork_http.c"
3561
+ #line 3562 "pitchfork_http.c"
3561
3562
  switch( (*p) ) {
3562
3563
  case 33: goto tr178;
3563
3564
  case 58: goto tr179;
@@ -3583,18 +3584,18 @@ case 119:
3583
3584
  goto tr178;
3584
3585
  goto st0;
3585
3586
  tr181:
3586
- #line 323 "pitchfork_http.rl"
3587
+ #line 324 "pitchfork_http.rl"
3587
3588
  { MARK(mark, p); }
3588
3589
  goto st120;
3589
3590
  tr179:
3590
- #line 322 "pitchfork_http.rl"
3591
+ #line 323 "pitchfork_http.rl"
3591
3592
  { hp->s.field_len = LEN(start.field, p); }
3592
3593
  goto st120;
3593
3594
  st120:
3594
3595
  if ( ++p == pe )
3595
3596
  goto _test_eof120;
3596
3597
  case 120:
3597
- #line 3598 "pitchfork_http.c"
3598
+ #line 3599 "pitchfork_http.c"
3598
3599
  switch( (*p) ) {
3599
3600
  case 9: goto tr181;
3600
3601
  case 10: goto tr182;
@@ -3606,14 +3607,14 @@ case 120:
3606
3607
  goto st0;
3607
3608
  goto tr180;
3608
3609
  tr180:
3609
- #line 323 "pitchfork_http.rl"
3610
+ #line 324 "pitchfork_http.rl"
3610
3611
  { MARK(mark, p); }
3611
3612
  goto st121;
3612
3613
  st121:
3613
3614
  if ( ++p == pe )
3614
3615
  goto _test_eof121;
3615
3616
  case 121:
3616
- #line 3617 "pitchfork_http.c"
3617
+ #line 3618 "pitchfork_http.c"
3617
3618
  switch( (*p) ) {
3618
3619
  case 10: goto tr185;
3619
3620
  case 13: goto tr186;
@@ -3754,7 +3755,7 @@ case 121:
3754
3755
  _out: {}
3755
3756
  }
3756
3757
 
3757
- #line 464 "pitchfork_http.rl"
3758
+ #line 465 "pitchfork_http.rl"
3758
3759
  post_exec: /* "_out:" also goes here */
3759
3760
  if (hp->cs != http_parser_error)
3760
3761
  hp->cs = cs;
@@ -4254,7 +4255,7 @@ static VALUE HttpParser_rssget(VALUE self)
4254
4255
  assert(!NIL_P(var) && "missed global field"); \
4255
4256
  } while (0)
4256
4257
 
4257
- void Init_pitchfork_http(void)
4258
+ RUBY_FUNC_EXPORTED void Init_pitchfork_http(void)
4258
4259
  {
4259
4260
  VALUE mPitchfork;
4260
4261
 
@@ -4318,5 +4319,6 @@ void Init_pitchfork_http(void)
4318
4319
 
4319
4320
  init_epollexclusive(mPitchfork);
4320
4321
  init_child_subreaper(mPitchfork);
4322
+ init_pitchfork_memory_page(mPitchfork);
4321
4323
  }
4322
4324
  #undef SET_GLOBAL