projects
/
metaproxy-moved-to-github.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d2a1afb
)
z3950_client: create close response if cs_connect fails
author
Adam Dickmeiss
<adam@indexdata.dk>
Wed, 3 Aug 2011 11:30:05 +0000
(13:30 +0200)
committer
Adam Dickmeiss
<adam@indexdata.dk>
Wed, 3 Aug 2011 11:30:05 +0000
(13:30 +0200)
Solves bug 2922.
src/filter_z3950_client.cpp
patch
|
blob
|
history
diff --git
a/src/filter_z3950_client.cpp
b/src/filter_z3950_client.cpp
index
0dcadcb
..
2ebe770
100644
(file)
--- a/
src/filter_z3950_client.cpp
+++ b/
src/filter_z3950_client.cpp
@@
-386,8
+386,16
@@
void yf::Z3950Client::Rep::send_and_receive(Package &package,
c->m_waiting = true;
if (!c->m_connected)
{
- c->client(c->m_host.c_str());
+ if (c->client(c->m_host.c_str()))
+ {
+ mp::odr odr;
+ package.response() =
+ odr.create_close(gdu->u.z3950, Z_Close_peerAbort, 0);
+ package.session().close();
+ return;
+ }
c->timeout(1); // so timeoutNotify gets called once per second
+
while (!c->m_destroyed && c->m_waiting
&& c->m_socket_manager->processEvent() > 0)