MCPcopy Create free account
hub / github.com/cgsecurity/testdisk / _date_get_days

Function _date_get_days

src/common.c:318–321  ·  view source on GitHub ↗

@ @ requires 0 <= days <= 334; @ requires 0 <= year <= 127; @ requires 0 <= leap_day <= 32; @ requires 0 <= day <= 30; @ terminates \true; @ ensures 0 <= \result <= 334 + 127 * 365 + 32 + 30 + DAYS_DELTA; @ assigns \nothing; @*/

Source from the content-addressed store, hash-verified

316 @ assigns \nothing;
317 @*/
318static unsigned long int _date_get_days(const unsigned long int days, const unsigned long int year, const unsigned long int leap_day, const unsigned long int day)
319{
320 return days + year * 365 + leap_day + day + DAYS_DELTA;
321}
322/*@
323 @ requires 0 <= seconds2 <= 31;
324 @ terminates \true;

Callers 1

date_dos2unixFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected