mirror of
https://github.com/Tha14/toxic.git
synced 2024-12-24 02:53:25 +01:00
move log struct to proper place
This commit is contained in:
parent
a5ce17f44e
commit
3baa830afb
@ -30,6 +30,7 @@
|
|||||||
#include "toxic_windows.h"
|
#include "toxic_windows.h"
|
||||||
#include "misc_tools.h"
|
#include "misc_tools.h"
|
||||||
#include "friendlist.h"
|
#include "friendlist.h"
|
||||||
|
#include "log.h"
|
||||||
#include "line_info.h"
|
#include "line_info.h"
|
||||||
|
|
||||||
extern char *DATA_FILE;
|
extern char *DATA_FILE;
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
#include "configdir.h"
|
#include "configdir.h"
|
||||||
#include "toxic_windows.h"
|
#include "toxic_windows.h"
|
||||||
#include "misc_tools.h"
|
#include "misc_tools.h"
|
||||||
|
#include "log.h"
|
||||||
|
|
||||||
/* Creates/fetches log file by appending to the config dir the name and a pseudo-unique identity */
|
/* Creates/fetches log file by appending to the config dir the name and a pseudo-unique identity */
|
||||||
void init_logging_session(uint8_t *name, uint8_t *key, struct chatlog *log)
|
void init_logging_session(uint8_t *name, uint8_t *key, struct chatlog *log)
|
||||||
|
@ -20,6 +20,15 @@
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#define LOG_FLUSH_LIMIT 2 /* limits calls to fflush(logfile) to a max of one per LOG_FLUSH_LIMIT seconds */
|
||||||
|
|
||||||
|
struct chatlog {
|
||||||
|
FILE *file;
|
||||||
|
uint64_t lastwrite;
|
||||||
|
int pos;
|
||||||
|
bool log_on; /* specific to current chat window */
|
||||||
|
};
|
||||||
|
|
||||||
/* Creates/fetches log file by appending to the config dir the name and a pseudo-unique identity */
|
/* Creates/fetches log file by appending to the config dir the name and a pseudo-unique identity */
|
||||||
void init_logging_session(uint8_t *name, uint8_t *key, struct chatlog *log);
|
void init_logging_session(uint8_t *name, uint8_t *key, struct chatlog *log);
|
||||||
|
|
||||||
|
@ -32,6 +32,7 @@
|
|||||||
#include "execute.h"
|
#include "execute.h"
|
||||||
#include "misc_tools.h"
|
#include "misc_tools.h"
|
||||||
#include "toxic_strings.h"
|
#include "toxic_strings.h"
|
||||||
|
#include "log.h"
|
||||||
#include "line_info.h"
|
#include "line_info.h"
|
||||||
|
|
||||||
uint8_t pending_frnd_requests[MAX_FRIENDS_NUM][TOX_CLIENT_ID_SIZE] = {0};
|
uint8_t pending_frnd_requests[MAX_FRIENDS_NUM][TOX_CLIENT_ID_SIZE] = {0};
|
||||||
|
@ -165,15 +165,6 @@ struct StatusBar {
|
|||||||
bool is_online;
|
bool is_online;
|
||||||
};
|
};
|
||||||
|
|
||||||
#define LOG_FLUSH_LIMIT 2 /* limits calls to fflush(logfile) to a max of one per LOG_FLUSH_LIMIT seconds */
|
|
||||||
|
|
||||||
struct chatlog {
|
|
||||||
FILE *file;
|
|
||||||
uint64_t lastwrite;
|
|
||||||
int pos;
|
|
||||||
bool log_on; /* specific to current chat window */
|
|
||||||
};
|
|
||||||
|
|
||||||
#define MAX_LINE_HIST 128
|
#define MAX_LINE_HIST 128
|
||||||
|
|
||||||
/* chat and groupchat window/buffer holder */
|
/* chat and groupchat window/buffer holder */
|
||||||
|
Loading…
Reference in New Issue
Block a user