Former-commit-id:a02aeb236c
[formerly9f19e3f712
] [formerlya02aeb236c
[formerly9f19e3f712
] [formerly06a8b51d6d
[formerly 64fa9254b946eae7e61bbc3f513b7c3696c4f54f]]] Former-commit-id:06a8b51d6d
Former-commit-id:8e80217e59
[formerly3360eb6c5f
] Former-commit-id:377dcd10b9
20 lines
447 B
C
20 lines
447 B
C
#include <time.h>
|
|
#include "time_convert.h"
|
|
|
|
/*----------------------------------------------------------------------------*/
|
|
/* function to return current time (GMT) in dtime_t format */
|
|
/*----------------------------------------------------------------------------*/
|
|
|
|
int current_GMT_dt(dtime_t *GMTtime_dt)
|
|
|
|
{
|
|
|
|
time_t GMTtime_t=0;
|
|
int ret;
|
|
|
|
time(&GMTtime_t);
|
|
ret = timet_to_yearsec_dt(GMTtime_t, GMTtime_dt);
|
|
|
|
return ret;
|
|
|
|
}
|