aboutsummaryrefslogtreecommitdiffstats
path: root/WireGuard/Shared/Logging/ringlogger.h
blob: 7f5b07496b6eb8c5f4d49a084f014a723e0ae666 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/* SPDX-License-Identifier: MIT
 *
 * Copyright © 2018-2019 WireGuard LLC. All Rights Reserved.
 */

#ifndef RINGLOGGER_H
#define RINGLOGGER_H

#include <stdint.h>

struct log;
void write_msg_to_log(struct log *log, const char *tag, const char *msg);
int write_log_to_file(const char *file_name, const struct log *input_log);
uint32_t view_lines_from_cursor(const struct log *input_log, uint32_t cursor, void(*)(const char *, uint64_t));
struct log *open_log(const char *file_name);
void close_log(struct log *log);

#endif