Merge pull request #972 in CASA/casa from CAS-12477 to master
* commit '1132681a524677baf3beaf7e138639ac1b1e87e4':
minor nullptr modernization, re-try builds, CAS-12477
ensure all temp records allocated by toRecord are released, CAS-12477
make sure all temporary records from toRecord are released, CAS-12477