Check before freeing