FreeTDM: Add gcc printf()-style format string checks to ftdm_log(), also add FTDM_(U)INT64_FMT and FTDM_TIME_FMT constants.

The format string checks already caught a couple crash-worthy bugs and this
commit fixes a couple more.

Also includes __ftdm_check_scanf(), for completeness (currently unused).

Signed-off-by: Stefan Knoblich <stkn@openisdn.net>
This commit is contained in:
Stefan Knoblich committed 2012-07-11 22:44:08 +02:00
1 parent 1e7d214ae6
commit f384e247fc
7 files changed
+48 -7

No files matched your search

+2
View File
@@ -53,6 +53,8 @@ extern "C" {
/*! \brief time data type */
typedef uint64_t ftdm_time_t;
/*! format string for ftdm_time_t */
#define FTDM_TIME_FMT FTDM_UINT64_FMT
/*! \brief sleep x amount of milliseconds */
#ifdef __WINDOWS__