#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <stdarg.h>
#include <string.h>
#include <time.h>
#include <errno.h>
int init_log(char *file_name, int file_size);
int write_log(const char *fmt, ...);
#define sys_log(format, args...) \
do \
{ \
write_log("%s(%d), %s:\n"format"\n", __FILE__, __LINE__, __FUNCTION__, ##args); \
} while (0)
#define sys_err_log(format, args...) \
do \
{ \
write_log("%s(%d), %s:\n"format":%s\n", __FILE__, __LINE__, __FUNCTION__, ##args, strerror(errno)); \
} while (0)
#define sys_err_log_quit(format, args...) \
do \