Blame SOURCES/libcgroup-0.41-api.c-preserve-dirty-flag.patch
|
|
2ae3c9 |
From ad27a46d8c0e180f71b4606d7b2a3bd3bebd7bbf Mon Sep 17 00:00:00 2001
|
|
|
2ae3c9 |
From: =?UTF-8?q?Nikola=20Forr=C3=B3?= <nforro@redhat.com>
|
|
|
2ae3c9 |
Date: Thu, 13 Oct 2016 13:42:30 +0200
|
|
|
2ae3c9 |
Subject: [PATCH] api.c: preserve dirty flag when copying controller values
|
|
|
2ae3c9 |
MIME-Version: 1.0
|
|
|
2ae3c9 |
Content-Type: text/plain; charset=UTF-8
|
|
|
2ae3c9 |
Content-Transfer-Encoding: 8bit
|
|
|
2ae3c9 |
|
|
|
2ae3c9 |
When setting cgroup parameters with cgset fails, no error is reported.
|
|
|
2ae3c9 |
This is caused by the fact that cgroup_copy_controller_values is not
|
|
|
2ae3c9 |
preserving dirty flags of the values, so it's making all errors
|
|
|
2ae3c9 |
considered non-fatal.
|
|
|
2ae3c9 |
|
|
|
2ae3c9 |
Signed-off-by: Nikola Forró <nforro@redhat.com>
|
|
|
2ae3c9 |
---
|
|
|
2ae3c9 |
src/api.c | 1 +
|
|
|
2ae3c9 |
1 file changed, 1 insertion(+)
|
|
|
2ae3c9 |
|
|
|
2ae3c9 |
diff --git a/src/api.c b/src/api.c
|
|
|
2ae3c9 |
index 0bf0615..daf4ef0 100644
|
|
|
2ae3c9 |
--- a/src/api.c
|
|
|
2ae3c9 |
+++ b/src/api.c
|
|
|
2ae3c9 |
@@ -1687,6 +1687,7 @@ static int cgroup_copy_controller_values(struct cgroup_controller *dst,
|
|
|
2ae3c9 |
dst_val = dst->values[i];
|
|
|
2ae3c9 |
strncpy(dst_val->value, src_val->value, CG_VALUE_MAX);
|
|
|
2ae3c9 |
strncpy(dst_val->name, src_val->name, FILENAME_MAX);
|
|
|
2ae3c9 |
+ dst_val->dirty = src_val->dirty;
|
|
|
2ae3c9 |
}
|
|
|
2ae3c9 |
err:
|
|
|
2ae3c9 |
return ret;
|
|
|
2ae3c9 |
--
|
|
|
2ae3c9 |
2.7.4
|
|
|
2ae3c9 |
|