Index: include/utils/utffile.h
===================================================================
--- include/utils/utffile.h	(revision 8227)
+++ include/utils/utffile.h	(working copy)
@@ -47,6 +47,7 @@
     wxMBConv *m_conversion;
     wxFontEncoding m_encoding;
     off_t m_bomOffset;
+    wxString m_strFileName;
 };
 
 #endif // _WX_UTFFILEH__
Index: utils/utffile.cpp
===================================================================
--- utils/utffile.cpp	(revision 8227)
+++ utils/utffile.cpp	(working copy)
@@ -31,6 +31,7 @@
 
 wxUtfFile::wxUtfFile(const wxChar *szFileName, OpenMode mode, wxFontEncoding encoding) : wxFile()
 {
+    m_strFileName = szFileName;
     Open(szFileName, mode, wxS_DEFAULT, encoding);
 }
 
@@ -77,6 +78,8 @@
 
             if (nLen == (size_t)-1)
             {
+                if (!m_strFileName.IsEmpty())
+                    wxLogWarning(_("file '%s' could not be opened because it contains characters that are not valid UTF-8. Please try again with the 'Read and write Unicode ITF-8 files' option turned off."), m_strFileName.c_str());
                 Seek(decr-nLen, wxFromCurrent);
                 return (size_t)-1;
             }
