]> git.saurik.com Git - apple/ipsec.git/blobdiff - ipsec-tools/racoon/handler.c
ipsec-92.4.tar.gz
[apple/ipsec.git] / ipsec-tools / racoon / handler.c
index a070970d3d8e7c3a5450340bcdcc539cce5bf382..9dc7f92da8216d3db08009d5e5d3e5a02d87dd19 100644 (file)
@@ -732,6 +732,14 @@ delph2(iph2)
                unlink_sainfo_from_ph2(iph2->sainfo);
                iph2->sainfo = NULL;
        }
+       if (iph2->ext_nat_id) {
+               vfree(iph2->ext_nat_id);
+               iph2->ext_nat_id = NULL;
+       }
+       if (iph2->ext_nat_id_p) {
+               vfree(iph2->ext_nat_id_p);
+               iph2->ext_nat_id_p = NULL;
+       }
 #endif
 
        racoon_free(iph2);
@@ -1195,7 +1203,7 @@ sweep_recvdpkt(dummy)
                }
        }
 
-       sched_new(lt, sweep_recvdpkt, NULL);
+       sched_new(lt, sweep_recvdpkt, &rcptree);
 }
 
 void
@@ -1208,6 +1216,7 @@ clear_recvdpkt()
                rem_recvdpkt(r);
                del_recvdpkt(r);
        }
+       sched_scrub_param(&rcptree);
 }
 
 void
@@ -1217,7 +1226,7 @@ init_recvdpkt()
 
        LIST_INIT(&rcptree);
 
-       sched_new(lt, sweep_recvdpkt, NULL);
+       sched_new(lt, sweep_recvdpkt, &rcptree);
 }
 
 #ifdef ENABLE_HYBRID