Fixed file opening in TECal