No content change, just code movement in preparation for the next
patch.
Signed-off-by: Alex Elder <aelder@sgi.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
char *mtab_file;
#define PROC_MOUNTS "/proc/self/mounts"
+static char *
+fs_device_number(
+ char *name,
+ dev_t *devnum)
+{
+ struct stat64 sbuf;
+
+ if (stat64(name, &sbuf) < 0)
+ return NULL;
+ *devnum = sbuf.st_dev;
+
+ return name;
+}
+
/*
* Find the FS table entry for the given path. The "flags" argument
* is a mask containing FS_MOUNT_POINT or FS_PROJECT_PATH (or both)
return NULL;
}
-static char *
-fs_device_number(
- char *name,
- dev_t *devnum)
-{
- struct stat64 sbuf;
-
- if (stat64(name, &sbuf) < 0)
- return NULL;
- *devnum = sbuf.st_dev;
-
- return name;
-}
-
static int
fs_table_insert(
char *dir,