Use tchar for error file path