| Line 7... |
Line 7... |
*
|
*
|
* Author: E.BERTIN, IAP & Leiden observatory
|
* Author: E.BERTIN, IAP & Leiden observatory
|
*
|
*
|
* Contents: main program.
|
* Contents: main program.
|
*
|
*
|
* Last modify: 24/09/2009
|
* Last modify: 21/01/2010
|
*
|
*
|
*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
*/
|
*/
|
|
|
#ifdef HAVE_CONFIG_H
|
#ifdef HAVE_CONFIG_H
|
| Line 45... |
Line 45... |
|
|
static int selectext(char *filename);
|
static int selectext(char *filename);
|
time_t thetimet, thetimet2;
|
time_t thetimet, thetimet2;
|
extern profitstruct *theprofit;
|
extern profitstruct *theprofit;
|
extern char profname[][32];
|
extern char profname[][32];
|
|
double dtime;
|
|
|
/******************************** makeit *************************************/
|
/******************************** makeit *************************************/
|
/*
|
/*
|
Manage the whole stuff.
|
Manage the whole stuff.
|
*/
|
*/
|
| Line 68... |
Line 69... |
|
|
/* Install error logging */
|
/* Install error logging */
|
error_installfunc(write_error);
|
error_installfunc(write_error);
|
|
|
/* Processing start date and time */
|
/* Processing start date and time */
|
|
dtime = counter_seconds();
|
thetimet = time(NULL);
|
thetimet = time(NULL);
|
tm = localtime(&thetimet);
|
tm = localtime(&thetimet);
|
sprintf(prefs.sdate_start,"%04d-%02d-%02d",
|
sprintf(prefs.sdate_start,"%04d-%02d-%02d",
|
tm->tm_year+1900, tm->tm_mon+1, tm->tm_mday);
|
tm->tm_year+1900, tm->tm_mon+1, tm->tm_mday);
|
sprintf(prefs.stime_start,"%02d:%02d:%02d",
|
sprintf(prefs.stime_start,"%02d:%02d:%02d",
|
| Line 530... |
Line 532... |
tm = localtime(&thetimet2);
|
tm = localtime(&thetimet2);
|
sprintf(prefs.sdate_end,"%04d-%02d-%02d",
|
sprintf(prefs.sdate_end,"%04d-%02d-%02d",
|
tm->tm_year+1900, tm->tm_mon+1, tm->tm_mday);
|
tm->tm_year+1900, tm->tm_mon+1, tm->tm_mday);
|
sprintf(prefs.stime_end,"%02d:%02d:%02d",
|
sprintf(prefs.stime_end,"%02d:%02d:%02d",
|
tm->tm_hour, tm->tm_min, tm->tm_sec);
|
tm->tm_hour, tm->tm_min, tm->tm_sec);
|
prefs.time_diff = difftime(thetimet2, thetimet);
|
prefs.time_diff = counter_seconds() - dtime;
|
|
|
/* Write XML */
|
/* Write XML */
|
if (prefs.xml_flag)
|
if (prefs.xml_flag)
|
write_xml(prefs.xml_name);
|
write_xml(prefs.xml_name);
|
|
|
| Line 619... |
Line 621... |
|
|
return;
|
return;
|
}
|
}
|
|
|
|
|
No newline at end of file
|
No newline at end of file
|
|
|
No newline at end of file
|
No newline at end of file
|