Bug 1074492: Only try to write to the results file if one is defined.