Fixed result file name handling