[IMP] Minor change to prevent memory leaks