Fix RAM usage