mirror of https://github.com/aria2/aria2
2010-10-27 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Added printf format check attribute. * src/Logger.h * src/StringFormat.hpull/1/head
parent
9f6b9fc175
commit
9ff8e55d04
|
@ -1,3 +1,9 @@
|
|||
2010-10-27 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
|
||||
|
||||
Added printf format check attribute.
|
||||
* src/Logger.h
|
||||
* src/StringFormat.h
|
||||
|
||||
2010-10-27 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
|
||||
|
||||
Use std::numeric_limits<time_t> instead of checking of
|
||||
|
|
30
src/Logger.h
30
src/Logger.h
|
@ -92,25 +92,35 @@ public:
|
|||
|
||||
virtual ~Logger();
|
||||
|
||||
void debug(const char* msg, ...);
|
||||
void debug(const char* msg, ...)
|
||||
__attribute__ ((format (printf, 2, 3)));
|
||||
|
||||
void debug(const char* msg, const Exception& ex, ...);
|
||||
void debug(const char* msg, const Exception& ex, ...)
|
||||
__attribute__ ((format (printf, 2, 4)));
|
||||
|
||||
void info(const char* msg, ...);
|
||||
void info(const char* msg, ...)
|
||||
__attribute__ ((format (printf, 2, 3)));
|
||||
|
||||
void info(const char* msg, const Exception& ex, ...);
|
||||
void info(const char* msg, const Exception& ex, ...)
|
||||
__attribute__ ((format (printf, 2, 4)));
|
||||
|
||||
void notice(const char* msg, ...);
|
||||
void notice(const char* msg, ...)
|
||||
__attribute__ ((format (printf, 2, 3)));
|
||||
|
||||
void notice(const char* msg, const Exception& ex, ...);
|
||||
void notice(const char* msg, const Exception& ex, ...)
|
||||
__attribute__ ((format (printf, 2, 4)));
|
||||
|
||||
void warn(const char* msg, ...);
|
||||
void warn(const char* msg, ...)
|
||||
__attribute__ ((format (printf, 2, 3)));
|
||||
|
||||
void warn(const char* msg, const Exception& ex, ...);
|
||||
void warn(const char* msg, const Exception& ex, ...)
|
||||
__attribute__ ((format (printf, 2, 4)));
|
||||
|
||||
void error(const char* msg, ...);
|
||||
void error(const char* msg, ...)
|
||||
__attribute__ ((format (printf, 2, 3)));
|
||||
|
||||
void error(const char* msg, const Exception& ex, ...);
|
||||
void error(const char* msg, const Exception& ex, ...)
|
||||
__attribute__ ((format (printf, 2, 4)));
|
||||
|
||||
void openFile(const std::string& filename);
|
||||
|
||||
|
|
|
@ -47,7 +47,8 @@ class StringFormat {
|
|||
private:
|
||||
std::string msg_;
|
||||
public:
|
||||
StringFormat(const char* fmt, ...);
|
||||
StringFormat(const char* fmt, ...)
|
||||
__attribute__ ((format (printf, 2, 3)));
|
||||
|
||||
const std::string& str() const;
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue