1
0

cherry-pick.v2.9.4-4-g805a0d1.fix-test-numbers.patch 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. Subject: Fix test numbers
  2. Origin: v2.9.4-4-g805a0d1 <https://github.com/joyent/http-parser/commit/805a0d1>
  3. Upstream-Author: Derek Argueta <deargueta@tesla.com>
  4. Date: Mon May 4 02:11:29 2020 -0700
  5. PR-URL: https://github.com/nodejs/http-parser/pull/511
  6. Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
  7. --- a/test.c
  8. +++ b/test.c
  9. @@ -1172,7 +1172,7 @@
  10. ,.body= ""
  11. }
  12. -#define SOURCE_ICE_REQUEST 42
  13. +#define SOURCE_ICE_REQUEST 43
  14. , {.name = "source request"
  15. ,.type= HTTP_REQUEST
  16. ,.raw= "SOURCE /music/sweet/music ICE/1.0\r\n"
  17. @@ -1192,7 +1192,7 @@
  18. ,.body= ""
  19. }
  20. -#define POST_MULTI_TE_LAST_CHUNKED 43
  21. +#define POST_MULTI_TE_LAST_CHUNKED 44
  22. , {.name= "post - multi coding transfer-encoding chunked body"
  23. ,.type= HTTP_REQUEST
  24. ,.raw= "POST / HTTP/1.1\r\n"
  25. @@ -1219,7 +1219,7 @@
  26. ,.chunk_lengths= { 0x1e }
  27. }
  28. -#define POST_MULTI_LINE_TE_LAST_CHUNKED 44
  29. +#define POST_MULTI_LINE_TE_LAST_CHUNKED 45
  30. , {.name= "post - multi line coding transfer-encoding chunked body"
  31. ,.type= HTTP_REQUEST
  32. ,.raw= "POST / HTTP/1.1\r\n"
  33. @@ -1821,7 +1821,7 @@
  34. ,.chunk_lengths= { 1 }
  35. }
  36. -#define EMPTY_REASON_PHRASE_AFTER_SPACE 20
  37. +#define EMPTY_REASON_PHRASE_AFTER_SPACE 21
  38. , {.name= "empty reason phrase after space"
  39. ,.type= HTTP_RESPONSE
  40. ,.raw= "HTTP/1.1 200 \r\n"
  41. @@ -1837,7 +1837,7 @@
  42. ,.body= ""
  43. }
  44. -#define CONTENT_LENGTH_X 21
  45. +#define CONTENT_LENGTH_X 22
  46. , {.name= "Content-Length-X"
  47. ,.type= HTTP_RESPONSE
  48. ,.raw= "HTTP/1.1 200 OK\r\n"
  49. @@ -1863,7 +1863,7 @@
  50. ,.chunk_lengths= { 2 }
  51. }
  52. -#define HTTP_101_RESPONSE_WITH_UPGRADE_HEADER 22
  53. +#define HTTP_101_RESPONSE_WITH_UPGRADE_HEADER 23
  54. , {.name= "HTTP 101 response with Upgrade header"
  55. ,.type= HTTP_RESPONSE
  56. ,.raw= "HTTP/1.1 101 Switching Protocols\r\n"
  57. @@ -1885,7 +1885,7 @@
  58. }
  59. }
  60. -#define HTTP_101_RESPONSE_WITH_UPGRADE_HEADER_AND_CONTENT_LENGTH 23
  61. +#define HTTP_101_RESPONSE_WITH_UPGRADE_HEADER_AND_CONTENT_LENGTH 24
  62. , {.name= "HTTP 101 response with Upgrade and Content-Length header"
  63. ,.type= HTTP_RESPONSE
  64. ,.raw= "HTTP/1.1 101 Switching Protocols\r\n"
  65. @@ -1911,7 +1911,7 @@
  66. }
  67. }
  68. -#define HTTP_101_RESPONSE_WITH_UPGRADE_HEADER_AND_TRANSFER_ENCODING 24
  69. +#define HTTP_101_RESPONSE_WITH_UPGRADE_HEADER_AND_TRANSFER_ENCODING 25
  70. , {.name= "HTTP 101 response with Upgrade and Transfer-Encoding header"
  71. ,.type= HTTP_RESPONSE
  72. ,.raw= "HTTP/1.1 101 Switching Protocols\r\n"
  73. @@ -1944,7 +1944,7 @@
  74. ,.chunk_lengths= { 2, 2 }
  75. }
  76. -#define HTTP_200_RESPONSE_WITH_UPGRADE_HEADER 25
  77. +#define HTTP_200_RESPONSE_WITH_UPGRADE_HEADER 26
  78. , {.name= "HTTP 200 response with Upgrade header"
  79. ,.type= HTTP_RESPONSE
  80. ,.raw= "HTTP/1.1 200 OK\r\n"
  81. @@ -1967,7 +1967,7 @@
  82. }
  83. }
  84. -#define HTTP_200_RESPONSE_WITH_UPGRADE_HEADER_AND_CONTENT_LENGTH 26
  85. +#define HTTP_200_RESPONSE_WITH_UPGRADE_HEADER_AND_CONTENT_LENGTH 27
  86. , {.name= "HTTP 200 response with Upgrade and Content-Length header"
  87. ,.type= HTTP_RESPONSE
  88. ,.raw= "HTTP/1.1 200 OK\r\n"
  89. @@ -1992,7 +1992,7 @@
  90. }
  91. }
  92. -#define HTTP_200_RESPONSE_WITH_UPGRADE_HEADER_AND_TRANSFER_ENCODING 27
  93. +#define HTTP_200_RESPONSE_WITH_UPGRADE_HEADER_AND_TRANSFER_ENCODING 28
  94. , {.name= "HTTP 200 response with Upgrade and Transfer-Encoding header"
  95. ,.type= HTTP_RESPONSE
  96. ,.raw= "HTTP/1.1 200 OK\r\n"
  97. @@ -2023,7 +2023,7 @@
  98. ,.num_chunks_complete= 3
  99. ,.chunk_lengths= { 2, 2 }
  100. }
  101. -#define HTTP_200_MULTI_TE_NOT_LAST_CHUNKED 28
  102. +#define HTTP_200_MULTI_TE_NOT_LAST_CHUNKED 29
  103. , {.name= "HTTP 200 response with `chunked` being *not last* Transfer-Encoding"
  104. ,.type= HTTP_RESPONSE
  105. ,.raw= "HTTP/1.1 200 OK\r\n"