| 732 | } |
| 733 | |
| 734 | int Stream::SetFailed(StreamId id, int error_code, const char* reason_fmt, ...) { |
| 735 | SocketUniquePtr ptr; |
| 736 | if (Socket::AddressFailedAsWell(id, &ptr) == -1) { |
| 737 | // Don't care recycled stream |
| 738 | return 0; |
| 739 | } |
| 740 | Stream* s = (Stream*)ptr->conn(); |
| 741 | va_list ap; |
| 742 | va_start(ap, reason_fmt); |
| 743 | s->Close(error_code, reason_fmt, ap); |
| 744 | va_end(ap); |
| 745 | return 0; |
| 746 | } |
| 747 | |
| 748 | int Stream::SetFailed(const StreamIds& ids, int error_code, const char* reason_fmt, ...) { |
| 749 | va_list ap; |