core: Use zalloc() to make the code more robust

Recently we had a problem where it was assumed that a field was
initialized to zeros but the constructor was using malloc(), check
all use and switch cus__new() to zalloc() to prevent such problems.

The other cases are clone() operations, so no sense in zeroing newly
allocated memory since it will be copied from some other similar
struct.

Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
1 file changed