Fix ZOOM: crash extended services diagnostics YAZ-846
[yaz-moved-to-github.git] / src / zoom-p.h
index bb6db6f..79f2f44 100644 (file)
@@ -36,7 +36,7 @@
 #include <yaz/srw.h>
 #include <yaz/cookie.h>
 #include <yaz/mutex.h>
-#if HAVE_LIBMEMCACHED_MEMCACHED_H
+#if HAVE_LIBMEMCACHED
 #include <libmemcached/memcached.h>
 #endif
 #if HAVE_HIREDIS
@@ -83,6 +83,7 @@ struct ZOOM_connection_p {
     int len_out;
     char *proxy;
     char *tproxy;
+    int proxy_mode;
     char *charset;
     char *lang;
     char *cookie_out;
@@ -115,12 +116,14 @@ struct ZOOM_connection_p {
     int log_details;
     int log_api;
     WRBUF saveAPDU_wrbuf;
-#if HAVE_LIBMEMCACHED_MEMCACHED_H
+#if HAVE_LIBMEMCACHED
     memcached_st *mc_st;
 #endif
 #if HAVE_HIREDIS
     redisContext *redis_c;
 #endif
+    int expire_search;
+    int expire_record;
 };
 
 typedef struct ZOOM_record_cache_p *ZOOM_record_cache;
@@ -244,6 +247,7 @@ zoom_ret ZOOM_connection_Z3950_send_init(ZOOM_connection c);
 
 ZOOM_task ZOOM_connection_add_task(ZOOM_connection c, int which);
 void ZOOM_connection_remove_task(ZOOM_connection c);
+void ZOOM_connection_remove_tasks(ZOOM_connection c);
 int ZOOM_test_reconnect(ZOOM_connection c);
 
 ZOOM_record ZOOM_record_cache_lookup(ZOOM_resultset r, int pos,