FIX deallocate memory