[gnome-control-center] info: Ignore NFS mounts when calculating disk size
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-control-center] info: Ignore NFS mounts when calculating disk size
- Date: Thu, 19 Apr 2012 11:03:10 +0000 (UTC)
commit 9c56a95358fd2fa2d7692a040ce6bca2db81007c
Author: Bastien Nocera <hadess hadess net>
Date: Thu Apr 19 12:00:04 2012 +0100
info: Ignore NFS mounts when calculating disk size
https://bugzilla.gnome.org/show_bug.cgi?id=674356
panels/info/Makefile.am | 4 +++-
panels/info/cc-info-panel.c | 6 ++++--
2 files changed, 7 insertions(+), 3 deletions(-)
---
diff --git a/panels/info/Makefile.am b/panels/info/Makefile.am
index fa58fd6..9eef9e0 100644
--- a/panels/info/Makefile.am
+++ b/panels/info/Makefile.am
@@ -28,7 +28,9 @@ libinfo_la_SOURCES = \
cc-info-panel.c \
cc-info-panel.h \
hostname-helper.c \
- hostname-helper.h
+ hostname-helper.h \
+ gsd-disk-space-helper.h \
+ gsd-disk-space-helper.c
libinfo_la_LIBADD = $(PANEL_LIBS) $(INFO_PANEL_LIBS)
libinfo_la_LDFLAGS = $(PANEL_LDFLAGS)
diff --git a/panels/info/cc-info-panel.c b/panels/info/cc-info-panel.c
index 0ecb472..226d201 100644
--- a/panels/info/cc-info-panel.c
+++ b/panels/info/cc-info-panel.c
@@ -36,6 +36,7 @@
#include <glibtop/sysinfo.h>
#include "hostname-helper.h"
+#include "gsd-disk-space-helper.h"
/* Autorun options */
#define PREF_MEDIA_AUTORUN_NEVER "autorun-never"
@@ -663,8 +664,9 @@ get_primary_disc_info (CcInfoPanel *self)
mount_path = g_unix_mount_get_mount_path (mount);
- if (g_str_has_prefix (mount_path, "/media/")
- || g_str_has_prefix (mount_path, g_get_home_dir ()))
+ if (gsd_should_ignore_unix_mount (mount) ||
+ g_str_has_prefix (mount_path, "/media/") ||
+ g_str_has_prefix (mount_path, g_get_home_dir ()))
{
g_unix_mount_free (mount);
continue;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]