Skip to content

Commit 3cb4e97

Browse files
author
Guillaume Quintard
committed
fix the clean function, scrap ip2proxy_data_t
1 parent 053eb0e commit 3cb4e97

File tree

1 file changed

+2
-12
lines changed

1 file changed

+2
-12
lines changed

src/vmod_ip2proxy.c

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -23,20 +23,10 @@
2323

2424
#include "cache/cache.h"
2525

26-
typedef struct vmod_ip2proxy_data {
27-
time_t ip2proxy_db_ts; /* timestamp of the database file */
28-
IP2Proxy *ip2proxy_handle;
29-
pthread_mutex_t lock;
30-
} ip2proxy_data_t;
31-
3226
void
33-
ip2proxy_free(void *d)
27+
ip2proxy_free(void *ptr)
3428
{
35-
ip2proxy_data_t *data = d;
36-
37-
if (data->ip2proxy_handle != NULL) {
38-
IP2Proxy_close(data->ip2proxy_handle);
39-
}
29+
IP2Proxy_close((IP2Proxy *)ptr);
4030
}
4131

4232
VCL_VOID

0 commit comments

Comments
 (0)