diff --git a/dap-sdk/net/server/http_server/dap_http_simple.c b/dap-sdk/net/server/http_server/dap_http_simple.c index b36d6e14260c4aae915e09949445ad104384f661..73ac61954dc5fdc34273c04bb9dc622982215cec 100644 --- a/dap-sdk/net/server/http_server/dap_http_simple.c +++ b/dap-sdk/net/server/http_server/dap_http_simple.c @@ -115,7 +115,7 @@ void dap_http_simple_module_deinit( void ) * @param a_reply_size_max Maximum reply size * @param a_callback Callback for data processing */ -void dap_http_simple_proc_add( dap_http_t *a_http, const char *a_url_path, size_t a_reply_size_max, dap_http_simple_callback_t a_callback ) +struct dap_http_simple_url_proc * dap_http_simple_proc_add( dap_http_t *a_http, const char *a_url_path, size_t a_reply_size_max, dap_http_simple_callback_t a_callback ) { dap_http_simple_url_proc_t *l_url_proc = DAP_NEW_Z( dap_http_simple_url_proc_t ); @@ -129,6 +129,7 @@ void dap_http_simple_proc_add( dap_http_t *a_http, const char *a_url_path, size_ s_http_client_headers_read, NULL, // Headers read, write s_http_client_data_read, s_http_client_data_write, // Data read, write NULL); // errror + return l_url_proc; } static void _free_user_agents_list() diff --git a/dap-sdk/net/server/http_server/include/dap_http_simple.h b/dap-sdk/net/server/http_server/include/dap_http_simple.h index a0d153403510fc84e6fabc33455ce94561dd0369..b3514fcef650429b013445fdfaf113c3d0fb2b03 100644 --- a/dap-sdk/net/server/http_server/include/dap_http_simple.h +++ b/dap-sdk/net/server/http_server/include/dap_http_simple.h @@ -64,7 +64,7 @@ typedef struct dap_http_simple { #define DAP_HTTP_SIMPLE(a) ((dap_http_simple_t*) (a)->_inheritor ) -void dap_http_simple_proc_add( dap_http_t *sh, const char *url_path, size_t reply_size_max, dap_http_simple_callback_t cb ); // Add simple processor +struct dap_http_simple_url_proc * dap_http_simple_proc_add( dap_http_t *sh, const char *url_path, size_t reply_size_max, dap_http_simple_callback_t cb ); // Add simple processor int dap_http_simple_module_init( void ); void dap_http_simple_module_deinit(void); diff --git a/modules/net/dap_chain_net_news.h b/modules/net/dap_chain_net_news.h index 409063d83e76198351aee2916537c25dcac049ef..d3c82ce4658987c30e207472e51015d55c326c0f 100644 --- a/modules/net/dap_chain_net_news.h +++ b/modules/net/dap_chain_net_news.h @@ -25,3 +25,4 @@ #include "dap_http.h" int dap_chain_net_news_init(dap_http_t * a_http); +void dap_chain_net_srv_vpn_cdb_news_cache_reset(void); diff --git a/modules/service/vpn/include/dap_chain_net_srv_vpn_cdb_server_list.h b/modules/service/vpn/include/dap_chain_net_srv_vpn_cdb_server_list.h index 6978da7a5bee68d591b8b16925e5cf7f05e82498..1aa4f8be6c3d5aed3da64426dff8392cbe31cbb5 100644 --- a/modules/service/vpn/include/dap_chain_net_srv_vpn_cdb_server_list.h +++ b/modules/service/vpn/include/dap_chain_net_srv_vpn_cdb_server_list.h @@ -37,5 +37,6 @@ int dap_chain_net_srv_vpn_cdb_server_list_init(void); void dap_chain_net_srv_vpn_cdb_server_list_deinit(void); void dap_chain_net_srv_vpn_cdb_server_list_add_proc(struct dap_http * sh, const char * url); +void dap_chain_net_srv_vpn_cdb_server_list_cache_reset(void); int dap_chain_net_srv_vpn_cdb_server_list_static_create(dap_chain_net_t *a_net);