From 5d925ef0068200dbdede9e4a05e9983867649022 Mon Sep 17 00:00:00 2001 From: Theodore Ts'o Date: Mon, 8 Dec 2008 15:05:03 +0100 Subject: [PATCH] blkid: Unexport the private symbol blkid_devdirs blkid_devdirs was defined in blkidP.h and was never intended to be used outside of the library. Since it no longer needs to be shared across object files, rename it and turn it into a static variable. Signed-off-by: Theodore Ts'o Signed-off-by: Karel Zak --- libs/blkid/src/blkidP.h | 1 - libs/blkid/src/devno.c | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/libs/blkid/src/blkidP.h b/libs/blkid/src/blkidP.h index 3c55a5b0..15999398 100644 --- a/libs/blkid/src/blkidP.h +++ b/libs/blkid/src/blkidP.h @@ -180,7 +180,6 @@ extern char *blkid_strdup(const char *s); extern char *blkid_strndup(const char *s, const int length); #define BLKID_CACHE_FILE "/etc/blkid.tab" -extern const char *blkid_devdirs[]; #define BLKID_ERR_IO 5 #define BLKID_ERR_PROC 9 diff --git a/libs/blkid/src/devno.c b/libs/blkid/src/devno.c index 9aec187d..0a16d9be 100644 --- a/libs/blkid/src/devno.c +++ b/libs/blkid/src/devno.c @@ -131,7 +131,7 @@ void blkid__scan_dir(char *dirname, dev_t devno, struct dir_list **list, } /* Directories where we will try to search for device numbers */ -const char *blkid_devdirs[] = { "/devices", "/devfs", "/dev", NULL }; +static const char *devdirs[] = { "/devices", "/devfs", "/dev", NULL }; /* * This function finds the pathname to a block device with a given @@ -148,7 +148,7 @@ char *blkid_devno_to_devname(dev_t devno) * Add the starting directories to search in reverse order of * importance, since we are using a stack... */ - for (dir = blkid_devdirs; *dir; dir++) + for (dir = devdirs; *dir; dir++) add_to_dirlist(*dir, &list); while (list) { -- 2.39.5