diff options
Diffstat (limited to 'src/proxy.cc')
| -rw-r--r-- | src/proxy.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/proxy.cc b/src/proxy.cc index bec4924..97180ca 100644 --- a/src/proxy.cc +++ b/src/proxy.cc @@ -572,7 +572,12 @@ void ProxyImpl::close_client(size_t index) { auto& client = clients_[index]; if (client.pkg_id != 0) { size_t avail; - auto ptr = client.in->read_ptr(&avail); + void const* ptr; + if (client.in) { + ptr = client.in->read_ptr(&avail); + } else { + avail = 0; + } if (avail) { send_attached_data(client.pkg_id, ptr, avail, true); } else { |
