compiler/libec: Fixed more memory leaks