Mercurial > hg > toybox
changeset 882:ae7a0fd5363f
Remove leaked global path_mounts.
author | Rob Landley <rob@landley.net> |
---|---|
date | Fri, 26 Apr 2013 01:59:13 -0500 |
parents | 2945e3cbebf2 |
children | aca8323e2690 |
files | lib/getmountlist.c |
diffstat | 1 files changed, 1 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/lib/getmountlist.c Fri Apr 26 01:47:59 2013 -0500 +++ b/lib/getmountlist.c Fri Apr 26 01:59:13 2013 -0500 @@ -7,8 +7,6 @@ #include <mntent.h> -char *path_mounts = "/proc/mounts"; - // Get a list of mount points from /etc/mtab or /proc/mounts, including // statvfs() information. This returns a reversed list, which is good for // finding overmounts and such. @@ -18,7 +16,7 @@ FILE *fp; struct mtab_list *mtlist, *mt; struct mntent me; - char evilbuf[2*PATH_MAX]; + char evilbuf[2*PATH_MAX], *path_mounts = "/proc/mounts"; mtlist = 0; if (!(fp = setmntent(path_mounts, "r"))) {