Fix record handling.