MCPcopy Create free account
hub / github.com/cppcheck-opensource/cppcheck / getLocaltime

Function getLocaltime

externals/simplecpp/simplecpp.cpp:3316–3326  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3314}
3315
3316static void getLocaltime(struct tm &ltime)
3317{
3318 time_t t;
3319 time(&t);
3320#ifndef _WIN32
3321 // NOLINTNEXTLINE(misc-include-cleaner) - false positive
3322 localtime_r(&t, &ltime);
3323#else
3324 localtime_s(&ltime, &t);
3325#endif
3326}
3327
3328static std::string getDateDefine(const struct tm *timep)
3329{

Callers 1

preprocessMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected