This patch augments the XML dumps with a 'directivelist' subnode which lists all raw preprocessor directives met while reading the source code in each configuration. Also, the addons/cppcheckdata.py file has been extended to give easy access to the list of directives and to provide Python support for the --template (or short -t) option. Finally, an new addon, addons/y2038/y2038.py, is created to detect when a glibc symbol might be Y2038-sensitive, based on whether and how _TIME_BITS and _USE_TIME_BITS64 are defined when meeting the symbol.
19 lines
282 B
C
19 lines
282 B
C
#include <stdio.h>
|
|
#include <fcntl.h>
|
|
|
|
/*
|
|
* Define _TIME_BITS unequal to 64 to trigger error
|
|
*/
|
|
|
|
#define _TIME_BITS 62
|
|
|
|
#include "y2038-inc.h"
|
|
|
|
int main(int argc, char **argv)
|
|
{
|
|
clockid_t my_clk_id;
|
|
struct timespec *my_tp;
|
|
|
|
return clock_gettime( my_clk_id, &my_tp);
|
|
}
|