Differences From Artifact [8ee3bb44d0]:
- File
src/OFHTTPClient.m
— part of check-in
[4af49a13c3]
at
2017-05-07 20:10:13
on branch trunk
— Small code style change
Casts are now written like types in variable declarations. (user: js, size: 17745) [annotate] [blame] [check-ins using]
To Artifact [530dbe6279]:
- File
src/OFHTTPClient.m
— part of check-in
[6b77a5dd8b]
at
2017-05-21 21:28:57
on branch trunk
— Prefix private methods with of_ instead of OF_
This matches Apple's style. (user: js, size: 17739) [annotate] [blame] [check-ins using]
︙ | |||
66 67 68 69 70 71 72 73 | 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 | + + - + + - - - - - | @interface OFHTTPClientResponse: OFHTTPResponse { OFTCPSocket *_socket; bool _hasContentLength, _chunked, _keepAlive, _atEndOfStream; size_t _toRead; } @property (nonatomic, setter=of_setKeepAlive:) bool of_keepAlive; - initWithSocket: (OFTCPSocket *)socket; |
︙ | |||
279 280 281 282 283 284 285 | 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 | - + | - (OFHTTPResponse *)performRequest: (OFHTTPRequest *)request { return [self performRequest: request redirects: 10]; } |
︙ | |||
365 366 367 368 369 370 371 | 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 | - + | } } } @finally { [_lastResponse release]; _lastResponse = nil; } } else |
︙ | |||
472 473 474 475 476 477 478 | 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 | - + - + | @try { [socket writeString: requestString]; } @catch (OFWriteFailedException *e) { if ([e errNo] != ECONNRESET && [e errNo] != EPIPE) @throw e; /* Reconnect in case a keep-alive connection timed out */ |
︙ | |||
603 604 605 606 607 608 609 | 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 | - + | keepAlive = ([connectionHeader caseInsensitiveCompare: @"keep-alive"] == OF_ORDERED_SAME); else keepAlive = false; } if (keepAlive) { |
︙ |