libipt_ACCOUNT: (tomj) fixed illegal handle free issue on deinit
authorThomas Jarosch <thomas.jarosch@intra2net.com>
Tue, 20 Apr 2004 13:19:06 +0000 (13:19 +0000)
committerThomas Jarosch <thomas.jarosch@intra2net.com>
Tue, 20 Apr 2004 13:19:06 +0000 (13:19 +0000)
src/ipt_ACCOUNT_cl.c

index d773b3d..aa4937a 100644 (file)
@@ -44,7 +44,7 @@ int ipt_ACCOUNT_init(struct ipt_ACCOUNT_context *ctx)
 
 void ipt_ACCOUNT_free_entries(struct ipt_ACCOUNT_context *ctx)
 {
-    if (ctx->handle.handle_nr >= 0)
+    if (ctx->handle.handle_nr != -1)
     {
         setsockopt(ctx->sockfd, IPPROTO_IP, IPT_SO_SET_ACCOUNT_HANDLE_FREE, &ctx->handle, sizeof (struct ipt_account_handle_sockopt));
         ctx->handle.handle_nr = -1;