mirror of
https://git.hardenedbsd.org/hardenedbsd/HardenedBSD.git
synced 2024-11-17 16:10:46 +01:00
Allocate memory as M_IPFW,now we can watch firewall memory usage
in vmstat..
This commit is contained in:
parent
1079e644a8
commit
9870b4d2de
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=7035
@ -523,7 +523,7 @@ int s=splnet();
|
||||
struct ip_fw *ftmp;
|
||||
ftmp = *chainptr;
|
||||
*chainptr = ftmp->fw_next;
|
||||
free(ftmp,M_SOOPTS);
|
||||
free(ftmp,M_IPFW);
|
||||
}
|
||||
splx(s);
|
||||
}
|
||||
@ -545,7 +545,7 @@ struct ip_fw *frwl;
|
||||
int addb4=0;
|
||||
int n_o,n_n;
|
||||
|
||||
ftmp = malloc(sizeof(struct ip_fw),M_SOOPTS,M_DONTWAIT);
|
||||
ftmp = malloc(sizeof(struct ip_fw),M_IPFW,M_DONTWAIT);
|
||||
if ( ftmp == NULL ) {
|
||||
dprintf1("ip_fw_ctl: malloc said no\n");
|
||||
splx(s);
|
||||
@ -751,13 +751,13 @@ struct ip_fw *frwl;
|
||||
if (ltmp)
|
||||
{
|
||||
ltmp->fw_next=ftmp->fw_next;
|
||||
free(ftmp,M_SOOPTS);
|
||||
free(ftmp,M_IPFW);
|
||||
ftmp=ltmp->fw_next;
|
||||
}
|
||||
else
|
||||
{
|
||||
*chainptr=ftmp->fw_next;
|
||||
free(ftmp,M_SOOPTS);
|
||||
free(ftmp,M_IPFW);
|
||||
ftmp=*chainptr;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user