[sysprof] helpers: allow /sys/ access too
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [sysprof] helpers: allow /sys/ access too
- Date: Wed, 29 May 2019 22:23:01 +0000 (UTC)
commit 297f1b70f5bf5234385665d214f1fa04f882b668
Author: Christian Hergert <chergert redhat com>
Date: Fri May 10 21:11:31 2019 -0700
helpers: allow /sys/ access too
src/helpers.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/src/helpers.c b/src/helpers.c
index 7aea216..b806466 100644
--- a/src/helpers.c
+++ b/src/helpers.c
@@ -277,7 +277,7 @@ helpers_get_proc_file (const gchar *path,
canon = g_file_get_path (file);
return g_file_is_native (file) &&
- g_str_has_prefix (canon, "/proc/") &&
+ (g_str_has_prefix (canon, "/proc/") || g_str_has_prefix (canon, "/sys/")) &&
g_file_get_contents (canon, contents, len, NULL);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]