diff --git a/utils/tex2rtf/src/htmlutil.cpp b/utils/tex2rtf/src/htmlutil.cpp
index f95065016d..c91ca52c9f 100644
--- a/utils/tex2rtf/src/htmlutil.cpp
+++ b/utils/tex2rtf/src/htmlutil.cpp
@@ -1907,6 +1907,9 @@ bool HTMLOnArgument(int macroId, int arg_no, bool start)
if (helpRefText)
TraverseChildrenFromChunk(helpRefText);
TexOutput(" (REF NOT FOUND)");
+ wxString errBuf;
+ errBuf.Printf("Warning: unresolved reference '%s'", refName);
+ OnInform((char *)errBuf.c_str());
}
}
else TexOutput("??");
diff --git a/utils/tex2rtf/src/rtfutils.cpp b/utils/tex2rtf/src/rtfutils.cpp
index c3a3968f1b..3a596413a8 100644
--- a/utils/tex2rtf/src/rtfutils.cpp
+++ b/utils/tex2rtf/src/rtfutils.cpp
@@ -3375,7 +3375,7 @@ bool RTFOnArgument(int macroId, int arg_no, bool start)
else
{
TexOutput("??");
- sprintf(buf, "Warning: unresolved reference %s.", refName);
+ sprintf(buf, "Warning: unresolved reference '%s'", refName);
OnInform(buf);
}
}
diff --git a/utils/tex2rtf/src/tex2any.cpp b/utils/tex2rtf/src/tex2any.cpp
index d689c9e17e..4f63fba613 100644
--- a/utils/tex2rtf/src/tex2any.cpp
+++ b/utils/tex2rtf/src/tex2any.cpp
@@ -600,7 +600,8 @@ bool read_a_line(char *buf)
errBuf.Printf("An underscore ('_') was detected at line %lu inside file %s that may need a '\\' before it.",LineNumbers[CurrentInputIndex], (const char*) currentFileName.c_str());
OnError((char *)errBuf.c_str());
}
- else if ((buf[bufIndex-1] != '\\') && (buf[0] != '%')) // If it is a comment line, then no warnings
+ else if ((buf[bufIndex-1] != '\\') && (buf[0] != '%') && // If it is a comment line, then no warnings
+ (strncmp(buf, "\\input", 6))) // do not report filenames that have underscores in them
{
wxString errBuf;
errBuf.Printf("An underscore ('_') was detected at line %lu inside file %s that may need a '\\' before it.",LineNumbers[CurrentInputIndex], (const char*) currentFileName.c_str());
@@ -3133,7 +3134,7 @@ bool DefaultOnArgument(int macroId, int arg_no, bool start)
{
char buf[300];
TexOutput("??", TRUE);
- sprintf(buf, "Warning: unresolved reference %s.", refName);
+ sprintf(buf, "Warning: unresolved reference '%s'", refName);
OnInform(buf);
}
}