libct: rework child file descriptors

Signed-off-by: Andrey Vagin <avagin@openvz.org>