File: log.h

package info (click to toggle)
libimager-perl 0.50-1etch1
  • links: PTS
  • area: main
  • in suites: etch
  • size: 3,120 kB
  • ctags: 2,907
  • sloc: ansic: 21,092; perl: 15,461; makefile: 56
file content (26 lines) | stat: -rw-r--r-- 548 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#ifndef _LOG_H_
#define _LOG_H_

#include <stdio.h>
#include <stdarg.h>
#include <time.h>
/* 
   input:  name of file to log too
   input:  onoff, 0 means no logging
   global: creates a global variable FILE* lg_file
*/

void m_lhead ( const char *file, int line  );
void m_init_log( const char *name, int onoff );
void m_loog(int level,const char *msg, ... );
void m_fatal ( int exitcode,const char *fmt, ... );


#ifdef IMAGER_LOG
#define mm_log(x) { m_lhead(__FILE__,__LINE__); m_loog x; } 
#else
#define mm_log(x)
#endif


#endif /* _LOG_H_ */