[DF-185] More potential memoryleak fixes