summaryrefslogtreecommitdiff
path: root/src/quotacheck.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2011-03-14 23:41:47 +0100
committerLennart Poettering <lennart@poettering.net>2011-03-14 23:41:47 +0100
commit2fc9784656900c4dc3715db506096ddc23fdd87c (patch)
tree206971c3cd2ab712d6be0a2f98fdebe99748f9dc /src/quotacheck.c
parent1f16b4a6c496288aa62dc2ac973f88ca6c801b5d (diff)
container: skip a few things when we are run in a container such as accessing /proc/cmdline
Diffstat (limited to 'src/quotacheck.c')
-rw-r--r--src/quotacheck.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/quotacheck.c b/src/quotacheck.c
index da2da3b2e0..057d8617c2 100644
--- a/src/quotacheck.c
+++ b/src/quotacheck.c
@@ -35,6 +35,9 @@ static int parse_proc_cmdline(void) {
int r;
size_t l;
+ if (detect_virtualization(NULL) > 0)
+ return 0;
+
if ((r = read_one_line_file("/proc/cmdline", &line)) < 0) {
log_warning("Failed to read /proc/cmdline, ignoring: %s", strerror(-r));
return 0;