projects
/
pazpar2-moved-to-github.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
For sort, re-use non-idle clients
[pazpar2-moved-to-github.git]
/
src
/
connection.c
diff --git
a/src/connection.c
b/src/connection.c
index
e441514
..
02509cf
100644
(file)
--- a/
src/connection.c
+++ b/
src/connection.c
@@
-496,7
+496,8
@@
static int connection_connect(struct connection *con, iochan_man_t iochan_man)
int client_prep_connection(struct client *cl,
int operation_timeout, int session_timeout,
iochan_man_t iochan_man,
int client_prep_connection(struct client *cl,
int operation_timeout, int session_timeout,
iochan_man_t iochan_man,
- const struct timeval *abstime)
+ const struct timeval *abstime,
+ int ok_with_working)
{
struct connection *co;
struct session_database *sdb = client_get_database(cl);
{
struct connection *co;
struct session_database *sdb = client_get_database(cl);
@@
-525,7
+526,8
@@
int client_prep_connection(struct client *cl,
if (co)
{
assert(co->host);
if (co)
{
assert(co->host);
- if (co->host == host && client_get_state(cl) == Client_Idle)
+ if (co->host == host && (client_get_state(cl) == Client_Idle
+ || ok_with_working))
{
return 2;
}
{
return 2;
}