diff --git a/modules/rest_client/rest_methods.c b/modules/rest_client/rest_methods.c index 8b3d20872f5..0bdac16d987 100644 --- a/modules/rest_client/rest_methods.c +++ b/modules/rest_client/rest_methods.c @@ -631,8 +631,8 @@ void rcl_release_url(char *url_host, int update_conn_ts) void **connected_ts; connected_ts = map_get(rcl_connections, host_str); - if (connected_ts) - *connected_ts = (void *)(unsigned long)get_ticks(); + if (connected_ts && *connected_ts) + *(unsigned long *)(*connected_ts) = (unsigned long)get_ticks(); } pkg_free(url_host);