Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 1 | /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil -*- */ |
| 2 | /** |
| 3 | * Copyright (C) 2013 Regents of the University of California. |
| 4 | * @author: Jeff Thompson <jefft0@remap.ucla.edu> |
| 5 | * See COPYING for copyright and distribution information. |
| 6 | */ |
| 7 | |
Alexander Afanasyev | e2dcdfd | 2014-02-07 15:53:28 -0800 | [diff] [blame] | 8 | #include "common.hpp" |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 9 | |
Alexander Afanasyev | e2dcdfd | 2014-02-07 15:53:28 -0800 | [diff] [blame] | 10 | #include "unix-transport.hpp" |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 11 | |
Alexander Afanasyev | e2dcdfd | 2014-02-07 15:53:28 -0800 | [diff] [blame] | 12 | #include "../face.hpp" |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 13 | #include <cstdlib> |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 14 | |
| 15 | using namespace std; |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 16 | typedef boost::asio::local::stream_protocol protocol; |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 17 | |
| 18 | namespace ndn { |
| 19 | |
| 20 | const size_t MAX_LENGTH = 9000; |
| 21 | |
| 22 | class UnixTransport::Impl |
| 23 | { |
| 24 | public: |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 25 | Impl(UnixTransport &transport) |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 26 | : transport_(transport) |
| 27 | , socket_(*transport_.ioService_) |
| 28 | , partialDataSize_(0) |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 29 | , connectionInProgress_(false) |
Alexander Afanasyev | 0102be9 | 2014-01-09 14:31:09 -0800 | [diff] [blame] | 30 | , connectTimer_(*transport_.ioService_) |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 31 | { |
| 32 | } |
| 33 | |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 34 | void |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 35 | connectHandler(const boost::system::error_code& error) |
| 36 | { |
| 37 | connectionInProgress_ = false; |
Alexander Afanasyev | 0102be9 | 2014-01-09 14:31:09 -0800 | [diff] [blame] | 38 | connectTimer_.cancel(); |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 39 | |
| 40 | if (!error) |
| 41 | { |
| 42 | partialDataSize_ = 0; |
| 43 | socket_.async_receive(boost::asio::buffer(inputBuffer_, MAX_LENGTH), 0, |
Alexander Afanasyev | 3c03420 | 2014-01-06 00:06:48 -0800 | [diff] [blame] | 44 | func_lib::bind(&Impl::handle_async_receive, this, _1, _2)); |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 45 | |
| 46 | transport_.isConnected_ = true; |
| 47 | |
| 48 | for (std::list<Block>::iterator i = sendQueue_.begin(); i != sendQueue_.end(); ++i) |
| 49 | socket_.async_send(boost::asio::buffer(i->wire(), i->size()), |
Alexander Afanasyev | 3c03420 | 2014-01-06 00:06:48 -0800 | [diff] [blame] | 50 | func_lib::bind(&Impl::handle_async_send, this, _1, *i)); |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 51 | |
| 52 | sendQueue_.clear(); |
| 53 | } |
| 54 | else |
| 55 | { |
| 56 | // may need to throw exception |
| 57 | transport_.isConnected_ = false; |
Alexander Afanasyev | 8995f54 | 2014-01-17 15:33:44 -0800 | [diff] [blame] | 58 | transport_.close(); |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 59 | throw Transport::Error(error, "error while connecting to the forwarder"); |
| 60 | } |
| 61 | } |
Alexander Afanasyev | 0102be9 | 2014-01-09 14:31:09 -0800 | [diff] [blame] | 62 | |
| 63 | void |
| 64 | connectTimeoutHandler(const boost::system::error_code& error) |
| 65 | { |
| 66 | if (error) // e.g., cancelled timer |
| 67 | return; |
| 68 | |
| 69 | connectionInProgress_ = false; |
| 70 | transport_.isConnected_ = false; |
| 71 | socket_.close(); |
| 72 | throw Transport::Error(error, "error while connecting to the forwarder"); |
| 73 | } |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 74 | |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 75 | void |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 76 | connect() |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 77 | { |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 78 | if (!connectionInProgress_) { |
| 79 | connectionInProgress_ = true; |
Alexander Afanasyev | 0102be9 | 2014-01-09 14:31:09 -0800 | [diff] [blame] | 80 | |
| 81 | // Wait at most 4 seconds to connect |
| 82 | /// @todo Decide whether this number should be configurable |
| 83 | connectTimer_.expires_from_now(boost::posix_time::seconds(4)); |
| 84 | connectTimer_.async_wait(func_lib::bind(&Impl::connectTimeoutHandler, this, _1)); |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 85 | |
Alexander Afanasyev | 8995f54 | 2014-01-17 15:33:44 -0800 | [diff] [blame] | 86 | socket_.open(); |
| 87 | socket_.async_connect(protocol::endpoint(transport_.unixSocket_), |
| 88 | func_lib::bind(&Impl::connectHandler, this, _1)); |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 89 | } |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 90 | } |
| 91 | |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 92 | void |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 93 | close() |
| 94 | { |
Alexander Afanasyev | 0102be9 | 2014-01-09 14:31:09 -0800 | [diff] [blame] | 95 | connectTimer_.cancel(); |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 96 | socket_.close(); |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 97 | transport_.isConnected_ = false; |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 98 | } |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 99 | |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 100 | void |
| 101 | send(const Block& wire) |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 102 | { |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 103 | if (!transport_.isConnected_) |
| 104 | sendQueue_.push_back(wire); |
| 105 | else |
| 106 | socket_.async_send(boost::asio::buffer(wire.wire(), wire.size()), |
Alexander Afanasyev | 3c03420 | 2014-01-06 00:06:48 -0800 | [diff] [blame] | 107 | func_lib::bind(&Impl::handle_async_send, this, _1, wire)); |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 108 | } |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 109 | |
| 110 | inline void |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 111 | processAll(uint8_t* buffer, size_t& offset, size_t availableSize) |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 112 | { |
| 113 | while(offset < availableSize) |
| 114 | { |
| 115 | Block element(buffer + offset, availableSize - offset); |
| 116 | transport_.receive(element); |
| 117 | |
| 118 | offset += element.size(); |
| 119 | } |
| 120 | } |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 121 | |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 122 | void |
| 123 | handle_async_receive(const boost::system::error_code& error, std::size_t bytes_recvd) |
| 124 | { |
| 125 | /// @todo The socket is not datagram, so need to have internal buffer to handle partial data reception |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 126 | |
Alexander Afanasyev | a557d5a | 2013-12-28 21:59:03 -0800 | [diff] [blame] | 127 | if (error) |
| 128 | { |
Alexander Afanasyev | bf08211 | 2014-01-09 14:27:55 -0800 | [diff] [blame] | 129 | if (error == boost::system::errc::operation_canceled) { |
| 130 | // async receive has been explicitly cancelled (e.g., socket close) |
| 131 | return; |
| 132 | } |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 133 | |
Alexander Afanasyev | a557d5a | 2013-12-28 21:59:03 -0800 | [diff] [blame] | 134 | socket_.close(); // closing at this point may not be that necessary |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 135 | transport_.isConnected_ = true; |
| 136 | throw Transport::Error(error, "error while receiving data from socket"); |
Alexander Afanasyev | a557d5a | 2013-12-28 21:59:03 -0800 | [diff] [blame] | 137 | } |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 138 | |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 139 | if (!error && bytes_recvd > 0) |
| 140 | { |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 141 | // inputBuffer_ has bytes_recvd received bytes of data |
| 142 | if (partialDataSize_ > 0) |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 143 | { |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 144 | size_t newDataSize = std::min(bytes_recvd, MAX_LENGTH-partialDataSize_); |
Alexander Afanasyev | d409d59 | 2014-01-28 18:36:38 -0800 | [diff] [blame] | 145 | std::copy(inputBuffer_, inputBuffer_ + newDataSize, partialData_ + partialDataSize_); |
| 146 | |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 147 | partialDataSize_ += newDataSize; |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 148 | |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 149 | size_t offset = 0; |
| 150 | try |
| 151 | { |
| 152 | processAll(partialData_, offset, partialDataSize_); |
| 153 | |
| 154 | // no exceptions => processed the whole thing |
| 155 | if (bytes_recvd - newDataSize > 0) |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 156 | { |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 157 | // there is a little bit more data available |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 158 | |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 159 | offset = 0; |
| 160 | partialDataSize_ = bytes_recvd - newDataSize; |
Alexander Afanasyev | d409d59 | 2014-01-28 18:36:38 -0800 | [diff] [blame] | 161 | std::copy(inputBuffer_ + newDataSize, inputBuffer_ + newDataSize + partialDataSize_, partialData_); |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 162 | |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 163 | processAll(partialData_, offset, partialDataSize_); |
| 164 | |
| 165 | // no exceptions => processed the whole thing |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 166 | partialDataSize_ = 0; |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 167 | } |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 168 | else |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 169 | { |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 170 | // done processing |
| 171 | partialDataSize_ = 0; |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 172 | } |
| 173 | } |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 174 | catch(Tlv::Error &) |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 175 | { |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 176 | if (offset > 0) |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 177 | { |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 178 | partialDataSize_ -= offset; |
Alexander Afanasyev | d409d59 | 2014-01-28 18:36:38 -0800 | [diff] [blame] | 179 | std::copy(partialData_ + offset, partialData_ + offset + partialDataSize_, partialData_); |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 180 | } |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 181 | else if (offset == 0 && partialDataSize_ == MAX_LENGTH) |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 182 | { |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 183 | // very bad... should close connection |
| 184 | socket_.close(); |
| 185 | transport_.isConnected_ = true; |
| 186 | throw Transport::Error(boost::system::error_code(), "input buffer full, but a valid TLV cannot be decoded"); |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 187 | } |
| 188 | } |
| 189 | } |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 190 | else |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 191 | { |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 192 | size_t offset = 0; |
| 193 | try |
| 194 | { |
| 195 | processAll(inputBuffer_, offset, bytes_recvd); |
| 196 | } |
| 197 | catch(Tlv::Error &error) |
| 198 | { |
| 199 | if (offset > 0) |
| 200 | { |
| 201 | partialDataSize_ = bytes_recvd - offset; |
Alexander Afanasyev | d409d59 | 2014-01-28 18:36:38 -0800 | [diff] [blame] | 202 | std::copy(inputBuffer_ + offset, inputBuffer_ + offset + partialDataSize_, partialData_); |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 203 | } |
| 204 | } |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 205 | } |
| 206 | } |
| 207 | |
| 208 | socket_.async_receive(boost::asio::buffer(inputBuffer_, MAX_LENGTH), 0, |
Alexander Afanasyev | 3c03420 | 2014-01-06 00:06:48 -0800 | [diff] [blame] | 209 | func_lib::bind(&Impl::handle_async_receive, this, _1, _2)); |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 210 | } |
| 211 | |
| 212 | void |
| 213 | handle_async_send(const boost::system::error_code& error, const Block &wire) |
| 214 | { |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 215 | // pass (needed to keep data block alive during the send) |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 216 | } |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 217 | |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 218 | private: |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 219 | UnixTransport &transport_; |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 220 | |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 221 | protocol::socket socket_; |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 222 | uint8_t inputBuffer_[MAX_LENGTH]; |
Alexander Afanasyev | 328e23d | 2013-12-28 20:47:38 -0800 | [diff] [blame] | 223 | |
| 224 | uint8_t partialData_[MAX_LENGTH]; |
| 225 | size_t partialDataSize_; |
Alexander Afanasyev | 3ae2da2 | 2013-12-29 15:50:04 -0800 | [diff] [blame] | 226 | |
| 227 | std::list< Block > sendQueue_; |
| 228 | bool connectionInProgress_; |
Alexander Afanasyev | 0102be9 | 2014-01-09 14:31:09 -0800 | [diff] [blame] | 229 | |
| 230 | boost::asio::deadline_timer connectTimer_; |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 231 | }; |
| 232 | |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 233 | |
| 234 | UnixTransport::UnixTransport() |
| 235 | { |
| 236 | if (std::getenv("NFD") != 0) |
| 237 | unixSocket_ = "/var/run/nfd.sock"; |
| 238 | else |
| 239 | unixSocket_ = "/tmp/.ndnd.sock"; |
| 240 | } |
| 241 | |
| 242 | UnixTransport::UnixTransport(const std::string& unixSocket) |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 243 | : unixSocket_(unixSocket) |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 244 | { |
| 245 | } |
| 246 | |
| 247 | UnixTransport::~UnixTransport() |
| 248 | { |
| 249 | } |
| 250 | |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 251 | void |
| 252 | UnixTransport::connect(boost::asio::io_service& ioService, |
| 253 | const ReceiveCallback& receiveCallback) |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 254 | { |
Alexander Afanasyev | 50ca627 | 2014-01-09 23:23:54 -0800 | [diff] [blame] | 255 | if (!static_cast<bool>(impl_)) { |
| 256 | Transport::connect(ioService, receiveCallback); |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 257 | |
Alexander Afanasyev | 50ca627 | 2014-01-09 23:23:54 -0800 | [diff] [blame] | 258 | impl_ = ptr_lib::make_shared<UnixTransport::Impl> (ptr_lib::ref(*this)); |
| 259 | } |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 260 | impl_->connect(); |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 261 | } |
| 262 | |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 263 | void |
| 264 | UnixTransport::send(const Block& wire) |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 265 | { |
Alexander Afanasyev | e2e0d75 | 2014-01-03 13:30:30 -0800 | [diff] [blame] | 266 | impl_->send(wire); |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 267 | } |
| 268 | |
Alexander Afanasyev | f7ca320 | 2014-02-14 22:28:31 -0800 | [diff] [blame] | 269 | void |
Alexander Afanasyev | fe3b150 | 2013-12-18 16:45:03 -0800 | [diff] [blame] | 270 | UnixTransport::close() |
| 271 | { |
| 272 | impl_->close(); |
| 273 | } |
| 274 | |
| 275 | } |