opendir change: refinement
[minix.git] / commands / cron / misc.h
blobb8229b5443e1fd07de2a8265e0583fcf933369da
1 /* misc.h - miscellaneous stuff Author: Kees J. Bot
2 * 7 Dec 1996
3 */
4 #ifndef MISC__H
5 #define MISC__H
7 #include <time.h>
9 /* The name of the program. */
10 extern char *prog_name;
12 /* Where cron stores it pid. */
13 #define PIDFILE "/usr/run/cron.pid"
15 /* Cron's idea of the current time, and the time next to run something. */
16 extern time_t now;
17 extern time_t next;
19 /* Memory allocation. */
20 void *allocate(size_t len);
21 void deallocate(void *mem);
22 extern size_t alloc_count;
24 /* Logging, by syslog or to stderr. */
25 #if __minix_vmd || !__minix
26 #include <sys/syslog.h>
27 #else
28 enum log_dummy { LOG_ERR, LOG_CRIT, LOG_ALERT };
29 #define openlog(ident, opt, facility) ((void) 0)
30 #define closelog() ((void) 0)
31 #define setlogmask(mask) (0)
32 #endif
34 enum logto { SYSLOG, STDERR };
35 void selectlog(enum logto where);
36 void log(int level, const char *fmt, ...);
38 #endif /* MISC__H */
41 * $PchId: misc.h,v 1.3 2000/07/17 18:56:02 philip Exp $