Rev 1596 | Rev 1599 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | SVN | RSS feed
| Rev 1596 | Rev 1597 | ||
|---|---|---|---|
| Line 70... | Line 70... | ||
| 70 | 70 | ||
| 71 | Client::Disconnect(); |
71 | Client::Disconnect(); |
| 72 | } |
72 | } |
| 73 | 73 | ||
| 74 | void UdpClient::Send(type::Byteset data) |
74 | void UdpClient::Send(type::Byteset data) |
| - | 75 | { |
|
| - | 76 | try |
|
| 75 | { |
77 | { |
| 76 | if (this->socket_->is_open()) |
78 | if (this->socket_->is_open()) |
| 77 | { |
79 | { |
| 78 | this->socket_->send_to(boost::asio::buffer(data.Get(), data.GetMaxSize()), this->endpoint_); |
80 | this->socket_->send_to(boost::asio::buffer(data.Get(), data.GetMaxSize()), this->endpoint_); |
| 79 | } |
81 | } |
| 80 |
|
82 | } |
| - | 83 | catch (std::exception& e) |
|
| 81 | { |
84 | { |
| 82 | this->Disconnect(); |
85 | this->Disconnect(); |
| - | 86 | //throw std::runtime_error(e.what()); |
|
| 83 | } |
87 | } |
| 84 | } |
88 | } |
| 85 | 89 | ||
| 86 | void UdpClient::Read() |
90 | void UdpClient::Read() |
| 87 | { |
91 | { |