File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -24,6 +24,11 @@ using namespace types;
24
24
using printer::KleePrinter;
25
25
26
26
static const std::string KLEE_GLOBAL_VAR_H = " klee_global_var.h" ;
27
+ static const std::string CALLOC_DECLARATION = " extern\n "
28
+ " #ifdef __cplusplus\n "
29
+ " \" C\"\n "
30
+ " #endif\n "
31
+ " void* calloc(size_t num, size_t size);\n " ;
27
32
28
33
printer::KleePrinter::KleePrinter (const types::TypesHandler *typesHandler,
29
34
std::shared_ptr<BuildDatabase> buildDatabase,
@@ -76,9 +81,8 @@ fs::path KleePrinter::writeTmpKleeFile(
76
81
strDeclareVar (" int" , PrinterUtils::KLEE_PATH_FLAG, " 0" );
77
82
}
78
83
79
- strInclude (" klee/klee.h" );
80
- strInclude (" stdlib.h" , true );
81
- ss << NL;
84
+ strInclude (" klee/klee.h" ) << NL;
85
+ ss << CALLOC_DECLARATION << NL;
82
86
writeStubsForStructureFields (tests);
83
87
84
88
writeAccessPrivateMacros (typesHandler, tests, false );
You can’t perform that action at this time.
0 commit comments