fix teardown-cgroup

Due to an echo failing, all the pids are not removed from the tasks list. Ensure that does not happen.

Signed-off-by: Karol Wrona <k.wrona@samsung.com>