#include "ext2_fs.h"
#include "ext2fs.h"
+#ifdef HAVE_SETMNTENT
/*
* Check to see if a regular file is mounted.
* If /etc/mtab/ is a symlink of /proc/mounts, you will need the following check
return 0;
}
-#ifdef HAVE_SETMNTENT
/*
* Helper function which checks a file in /etc/mtab format to see if a
* filesystem is mounted. Returns an error if the file doesn't exist
#endif
}
+#ifdef CONFIG_MMP
static errcode_t ext2fs_mmp_reset(ext2_filsys fs)
{
struct mmp_struct *mmp_s = NULL;
out:
return retval;
}
+#endif
errcode_t ext2fs_mmp_update(ext2_filsys fs)
{
#include <dlfcn.h>
#endif
+#ifdef HAVE_DLOPEN
static void ss_release_readline(ss_data *info)
{
-#ifdef HAVE_DLOPEN
if (!info->readline_handle)
return;
info->rl_completion_matches = 0;
dlclose(info->readline_handle);
info->readline_handle = 0;
-#endif
}
+#endif
/* Libraries we will try to use for readline/editline functionality */
#define DEFAULT_LIBPATH "libreadline.so.6:libreadline.so.5:libreadline.so.4:libreadline.so:libedit.so.2:libedit.so:libeditline.so.0:libeditline.so"
return 0;
}
+#if defined(USE_UUIDD) && defined(HAVE_SYS_UN_H)
static ssize_t read_all(int fd, char *buf, size_t count)
{
ssize_t ret;
open("/dev/null", O_RDWR);
}
}
-
+#endif /* defined(USE_UUIDD) && defined(HAVE_SYS_UN_H) */
/*
* Try using the uuidd daemon to generate the UUID
}
}
-static int is_keyring_valid(const char *keyring)
-{
- return (get_keyring_id(keyring) != 0);
-}
-
void get_default_salts(void)
{
FILE *f = setmntent("/etc/mtab", "r");