]> git.ipfire.org Git - thirdparty/lxc.git/commit
cgm_get: make sure @value is null-terminated
authorSerge Hallyn <serge.hallyn@ubuntu.com>
Fri, 27 Jun 2014 18:51:33 +0000 (13:51 -0500)
committerStéphane Graber <stgraber@ubuntu.com>
Mon, 30 Jun 2014 16:42:27 +0000 (12:42 -0400)
commit08ddf801e315d500d3f4efb681ce675c402ebb67
tree805d422f960a1562e18d42b00182c8a77fba359e
parentfb6c761621909d546756821188adf4e6cc3f4944
cgm_get: make sure @value is null-terminated

Previously this was done by strncpy, but now we just read
the len bytes - not including \0 - from a pipe, so pre-fill
@value with 0s to be safe.

This fixes the python3 api_test failure.

Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com>
src/lxc/cgmanager.c