Confusing information was given to staff about a closed line on Auckland's southern railway, which nearly led to a collision, a report has found.
A freight train almost hit a mobile crane on the north-bound track at Wiri Junction in November 2011 when a controller sent a driver on the wrong route.
The driver managed to brake about 100 metres from the construction site.
The Transport Accident Investigation Commission says the driver should have challenged the controller when he questioned their instructions, and information given to staff about the closed lines was unclear.
The commission says KiwiRail immediately addressed specific safety concerns on the line, but says two of the three recommendations are still being looked at.