summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDimitri van Heesch <dimitri@stack.nl>2014-01-18 10:56:36 (GMT)
committerDimitri van Heesch <dimitri@stack.nl>2014-01-18 10:56:36 (GMT)
commit31505eb34565b2e39d113b7f5460645d02ad6d2e (patch)
tree43fbaf5763acaba686fe8399fbba188257d89dab
parentac813134a85ba9bd999fb4cf8271c74e02cd4ebb (diff)
downloadDoxygen-31505eb34565b2e39d113b7f5460645d02ad6d2e.zip
Doxygen-31505eb34565b2e39d113b7f5460645d02ad6d2e.tar.gz
Doxygen-31505eb34565b2e39d113b7f5460645d02ad6d2e.tar.bz2
Fixed potential crash caused by overloading the variadic warn function
-rw-r--r--src/message.cpp2
-rw-r--r--src/message.h2
-rw-r--r--src/template.cpp4
3 files changed, 4 insertions, 4 deletions
diff --git a/src/message.cpp b/src/message.cpp
index ff5dac2..dad3e0e 100644
--- a/src/message.cpp
+++ b/src/message.cpp
@@ -172,7 +172,7 @@ void warn(const char *file,int line,const char *fmt, ...)
va_end(args);
}
-void warn(const char *file,int line,const char *fmt,va_list args)
+void va_warn(const char *file,int line,const char *fmt,va_list args)
{
do_warn("WARNINGS", file, line, warning_str, fmt, args);
}
diff --git a/src/message.h b/src/message.h
index 2875e81..ca76a20 100644
--- a/src/message.h
+++ b/src/message.h
@@ -23,7 +23,7 @@
extern void msg(const char *fmt, ...);
extern void warn(const char *file,int line,const char *fmt, ...);
-extern void warn(const char *file,int line,const char *fmt, va_list args);
+extern void va_warn(const char *file,int line,const char *fmt, va_list args);
extern void warn_simple(const char *file,int line,const char *text);
extern void warn_undoc(const char *file,int line,const char *fmt, ...);
extern void warn_doc_error(const char *file,int line,const char *fmt, ...);
diff --git a/src/template.cpp b/src/template.cpp
index 793d769..ea3c673 100644
--- a/src/template.cpp
+++ b/src/template.cpp
@@ -1713,7 +1713,7 @@ void TemplateContextImpl::warn(const char *fileName,int line,const char *fmt,...
{
va_list args;
va_start(args,fmt);
- ::warn(fileName,line,fmt,args);
+ va_warn(fileName,line,fmt,args);
va_end(args);
m_engine->printIncludeContext(fileName,line);
}
@@ -3342,7 +3342,7 @@ void TemplateParser::warn(const char *fileName,int line,const char *fmt,...) con
{
va_list args;
va_start(args,fmt);
- ::warn(fileName,line,fmt,args);
+ va_warn(fileName,line,fmt,args);
va_end(args);
m_engine->printIncludeContext(fileName,line);
}