static void connection_handler(IOCHAN iochan, int event)
{
struct connection *co = iochan_getdata(iochan);
- struct client *cl = co->client;
+ struct client *cl;
struct host *host = co->host;
yaz_mutex_enter(host->mutex);
+ cl = co->client;
if (!cl)
{
/* no client associated with it.. We are probably getting
{
yaz_log(YLOG_WARN, "connect timeout %s", client_get_url(cl));
- connection_destroy(co);
client_set_state(cl, Client_Error);
+ connection_destroy(co);
}
else if (client_get_state(co->client) == Client_Idle)
{