Differences From Artifact [879c93d87f]:
- File src/OFHTTPServer.m — part of check-in [1a86b8175b] at 2022-02-12 07:46:07 on branch trunk — Update copyright (user: js, size: 19839) [annotate] [blame] [check-ins using] [more...]
To Artifact [e75cf57b42]:
- File
src/OFHTTPServer.m
— part of check-in
[3e455c4839]
at
2022-10-11 19:27:09
on branch trunk
— OFURI: Make scheme and path nonnull
This is as per the RFC, which says the scheme and path can never be
missing, while the path can be empty. (user: js, size: 20016) [annotate] [blame] [check-ins using] [more...]
︙ | |||
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | + + - + | * * Alternatively, it may be distributed under the terms of the GNU General * Public License, either version 2 or 3, which can be found in the file * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this * file. */ #define OF_HTTP_SERVER_M #include "config.h" #include <errno.h> #include <stdlib.h> #include <string.h> #import "OFHTTPServer.h" #import "OFArray.h" #import "OFData.h" #import "OFDate.h" #import "OFDictionary.h" #import "OFHTTPRequest.h" #import "OFHTTPResponse.h" #import "OFNumber.h" #import "OFSocket+Private.h" #import "OFTCPSocket.h" #import "OFThread.h" #import "OFTimer.h" |
︙ | |||
355 356 357 358 359 360 361 | 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 | - + | { OFString *method; OFMutableString *path; size_t pos; @try { OFString *version = [line |
︙ | |||
382 383 384 385 386 387 388 | 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 | - + | @try { _method = OFHTTPRequestMethodParseName(method); } @catch (OFInvalidArgumentException *e) { return [self sendErrorAndClose: 405]; } @try { |
︙ | |||
508 509 510 511 512 513 514 | 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 | - + - + - - + - + + - - + + + - - + + - - - - - - + + + + + + + + + + + - + | date, _server.name]; return false; } - (void)createResponse { void *pool = objc_autoreleasePoolPush(); |
︙ |