close_mib2 in sigar_os_close

This commit is contained in:
Doug MacEachern 2010-04-21 13:51:12 -07:00
parent 0bee437f85
commit 4b9e309c8b
1 changed files with 3 additions and 0 deletions

View File

@ -151,6 +151,9 @@ int sigar_os_open(sigar_t **sig)
int sigar_os_close(sigar_t *sigar)
{
kstat_close(sigar->kc);
if (sigar->mib2.sd != -1) {
close_mib2(&sigar->mib2);
}
if (sigar->ks.lcpu) {
free(sigar->ks.cpu);