1
2/*
3 * Copyright (C) NGINX, Inc.
4 * Copyright (C) Valentin V. Bartenev
5 */
6
7#include <nxt_main.h>
8

--- 195 unchanged lines hidden (view full) ---

204
205 p += 8;
206 }
207
208 while (p != end) {
209 nxt_method_test_char(*p); p++;
210 }
211
212 rp->method.length = p - rp->method.start;
213
214 return NXT_AGAIN;
215
216 method_unusual_char:
217
218 ch = *p;
219
220 if (nxt_fast_path(ch == ' ')) {
221 rp->method.length = p - rp->method.start;

--- 6 unchanged lines hidden (view full) ---

228 }
229
230 if (rp->method.start == p && (ch == NXT_CR || ch == NXT_LF)) {
231 rp->method.start++;
232 p++;
233 continue;
234 }
235
236 rp->method.length = p - rp->method.start;
237
238 return NXT_HTTP_PARSE_INVALID;
239 }
240
241 p++;
242
243 if (nxt_slow_path(p == end)) {
244 return NXT_AGAIN;
245 }

--- 1031 unchanged lines hidden ---