mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-10 03:16:17 +01:00
gunixmounts: Add missing const qualifier for mtab path
get_mtab_read_file and get_mtab_monitor_file returns const path, but const qualifier is missing. Let's add it. https://bugzilla.gnome.org/show_bug.cgi?id=779607
This commit is contained in:
parent
2db36d0d5c
commit
41a4a70b43
@ -437,7 +437,7 @@ _g_get_unix_mounts (void)
|
||||
|
||||
#else
|
||||
|
||||
static char *
|
||||
static const char *
|
||||
get_mtab_read_file (void)
|
||||
{
|
||||
#ifdef _PATH_MOUNTED
|
||||
@ -464,7 +464,7 @@ _g_get_unix_mounts (void)
|
||||
#endif
|
||||
struct mntent *mntent;
|
||||
FILE *file;
|
||||
char *read_file;
|
||||
const char *read_file;
|
||||
GUnixMountEntry *mount_entry;
|
||||
GHashTable *mounts_hash;
|
||||
GList *return_list;
|
||||
@ -538,10 +538,10 @@ _g_get_unix_mounts (void)
|
||||
|
||||
#endif /* HAVE_LIBMOUNT */
|
||||
|
||||
static char *
|
||||
static const char *
|
||||
get_mtab_monitor_file (void)
|
||||
{
|
||||
static char *mountinfo_path = NULL;
|
||||
static const char *mountinfo_path = NULL;
|
||||
#ifdef HAVE_LIBMOUNT
|
||||
struct stat buf;
|
||||
#endif
|
||||
@ -584,7 +584,7 @@ get_mtab_monitor_file (void)
|
||||
|
||||
G_LOCK_DEFINE_STATIC(getmntent);
|
||||
|
||||
static char *
|
||||
static const char *
|
||||
get_mtab_read_file (void)
|
||||
{
|
||||
#ifdef _PATH_MOUNTED
|
||||
@ -594,7 +594,7 @@ get_mtab_read_file (void)
|
||||
#endif
|
||||
}
|
||||
|
||||
static char *
|
||||
static const char *
|
||||
get_mtab_monitor_file (void)
|
||||
{
|
||||
return get_mtab_read_file ();
|
||||
@ -605,7 +605,7 @@ _g_get_unix_mounts (void)
|
||||
{
|
||||
struct mnttab mntent;
|
||||
FILE *file;
|
||||
char *read_file;
|
||||
const char *read_file;
|
||||
GUnixMountEntry *mount_entry;
|
||||
GList *return_list;
|
||||
|
||||
@ -645,7 +645,7 @@ _g_get_unix_mounts (void)
|
||||
/* mntctl.h (AIX) {{{2 */
|
||||
#elif defined(HAVE_SYS_MNTCTL_H) && defined(HAVE_SYS_VMOUNT_H) && defined(HAVE_SYS_VFS_H)
|
||||
|
||||
static char *
|
||||
static const char *
|
||||
get_mtab_monitor_file (void)
|
||||
{
|
||||
return NULL;
|
||||
@ -713,7 +713,7 @@ _g_get_unix_mounts (void)
|
||||
/* sys/mount.h {{{2 */
|
||||
#elif (defined(HAVE_GETVFSSTAT) || defined(HAVE_GETFSSTAT)) && defined(HAVE_FSTAB_H) && defined(HAVE_SYS_MOUNT_H)
|
||||
|
||||
static char *
|
||||
static const char *
|
||||
get_mtab_monitor_file (void)
|
||||
{
|
||||
return NULL;
|
||||
@ -784,7 +784,7 @@ _g_get_unix_mounts (void)
|
||||
/* Interix {{{2 */
|
||||
#elif defined(__INTERIX)
|
||||
|
||||
static char *
|
||||
static const char *
|
||||
get_mtab_monitor_file (void)
|
||||
{
|
||||
return NULL;
|
||||
|
Loading…
Reference in New Issue
Block a user