chiark / gitweb /
cgroup-util: fix enabling of controllers (#8816)
authorAntique <phrdina@redhat.com>
Thu, 26 Apr 2018 10:37:35 +0000 (12:37 +0200)
committerSven Eden <yamakuzure@gmx.net>
Thu, 28 Jun 2018 07:24:07 +0000 (09:24 +0200)
commit91b7eae095db9442e5473c626175185cf448ba51
tree9feea2db5fb2cfbbbc0e9a5684403476558557ef
parenta7803239f6da32aadca17593178ee24f06be6168
cgroup-util: fix enabling of controllers (#8816)

If enabling controller for some reason fails we need to clear error
for the FILE stream.  Enabling remaining controllers would otherwise
fail because write_string_stream_ts() checks for ferror(f) and returns
-EIO if there is one.

Broken by commit <77fa610b22>.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
(cherry picked from commit 96aa6591d1103b8cca9a4db80ba478a18bdf3e9a)
src/basic/cgroup-util.c