-/* @(#) $Id$ */
+/* @(#) $Id: ./src/monitord/monitord.c, 2011/09/08 dcid Exp $
+ */
/* Copyright (C) 2009 Trend Micro Inc.
* All rights reserved.
/* Real monitord global */
void Monitord()
{
- time_t tm;
- struct tm *p;
+ time_t tm;
+ struct tm *p;
- int today = 0;
+ int today = 0;
int thismonth = 0;
int thisyear = 0;
sleep(10);
memset(str, '\0', OS_SIZE_1024 +1);
-
-
+
+
/* Getting currently time before starting */
tm = time(NULL);
p = localtime(&tm);
-
+
today = p->tm_mday;
thismonth = p->tm_mon;
thisyear = p->tm_year+1900;
-
-
+
+
/* Connecting to the message queue
* Exit if it fails.
*/
merror(QUEUE_SEND, ARGV0);
}
-
+
/* Main monitor loop */
while(1)
{
{
monitor_agents();
}
-
+
/* Day changed, deal with log files */
if(today != p->tm_mday)
{