summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoralbert-github <albert.tests@gmail.com>2018-11-17 13:52:08 (GMT)
committeralbert-github <albert.tests@gmail.com>2018-11-17 13:52:08 (GMT)
commit21021ce13919d19ce5434a3db868c2d4f5a4a53c (patch)
treea67755e7209fb0be978b478bd0a52a404cfd2a37
parenta7803b58cf4359b0dbf44e3c4346283cc4242b6e (diff)
downloadDoxygen-21021ce13919d19ce5434a3db868c2d4f5a4a53c.zip
Doxygen-21021ce13919d19ce5434a3db868c2d4f5a4a53c.tar.gz
Doxygen-21021ce13919d19ce5434a3db868c2d4f5a4a53c.tar.bz2
Replace ''printf' with appropriate warn 'message'
In the code a 'printf' has been replaced with an appropriate 'warn' call (and renamed a local variable to prevent conflicts)
-rw-r--r--src/docparser.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/docparser.cpp b/src/docparser.cpp
index b414e8f..39978de 100644
--- a/src/docparser.cpp
+++ b/src/docparser.cpp
@@ -269,7 +269,7 @@ static void unescapeCRef(QCString &s)
* copies the image to the output directory (which depends on the \a type
* parameter).
*/
-static QCString findAndCopyImage(const char *fileName,DocImage::Type type, bool warn = true)
+static QCString findAndCopyImage(const char *fileName,DocImage::Type type, bool dowarn = true)
{
QCString result;
bool ambig;
@@ -337,7 +337,8 @@ static QCString findAndCopyImage(const char *fileName,DocImage::Type type, bool
}
else
{
- printf("Source and Destination are the same!\n");
+ warn(g_fileName,doctokenizerYYlineno,
+ "Prevented to copy file %s onto itself!\n",qPrint(inputFile));
}
}
else
@@ -365,7 +366,7 @@ static QCString findAndCopyImage(const char *fileName,DocImage::Type type, bool
return baseName;
}
}
- else if (ambig && warn)
+ else if (ambig && dowarn)
{
QCString text;
text.sprintf("image file name %s is ambiguous.\n",qPrint(fileName));
@@ -376,7 +377,7 @@ static QCString findAndCopyImage(const char *fileName,DocImage::Type type, bool
else
{
result=fileName;
- if (result.left(5)!="http:" && result.left(6)!="https:" && warn)
+ if (result.left(5)!="http:" && result.left(6)!="https:" && dowarn)
{
warn_doc_error(g_fileName,doctokenizerYYlineno,
"image file %s is not found in IMAGE_PATH: "