From: Timo Kokkonen Date: Fri, 23 Jul 2010 10:50:40 +0000 (+0300) Subject: parser: opendir_check: Open the correct directory X-Git-Url: http://git.itanic.dy.fi/?p=scan-pagemap;a=commitdiff_plain;h=d3642469cc857e5b14ead37cf6a1c301469497f9 parser: opendir_check: Open the correct directory Remove the incorrect hard coded directory since it is wrong. Signed-off-by: Timo Kokkonen --- diff --git a/parse.c b/parse.c index 678dda3..30a84a3 100644 --- a/parse.c +++ b/parse.c @@ -362,11 +362,11 @@ static int opendir_check(DIR **dir, const char *path) int error; if (!*dir) { - *dir = opendir("/proc"); + *dir = opendir(path); if (!dir) { error = errno; - fprintf(stderr, "Failed to open /proc directory: %s\n", - strerror(error)); + fprintf(stderr, "Failed to open %s directory: %s\n", + path, strerror(error)); return -1; } }