mountd: Avoid memory leak by freeing dp_dirp
Introduced in r324007, the data alloced by strdup was never free'ed. While here, remove cast to caddr_t when freeing dp. Reported by: bde MFC after: 1 week X MFC With: r324007
This commit is contained in:
parent
65d4f317ea
commit
92e73ccc73
@ -2159,7 +2159,8 @@ free_dir(struct dirlist *dp)
|
||||
free_dir(dp->dp_left);
|
||||
free_dir(dp->dp_right);
|
||||
free_host(dp->dp_hosts);
|
||||
free((caddr_t)dp);
|
||||
free(dp->dp_dirp);
|
||||
free(dp);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user