mirror of
https://github.com/gabime/spdlog.git
synced 2024-11-15 08:25:43 +08:00
Updated file_events example
This commit is contained in:
parent
30fb78813b
commit
b813bb863d
@ -316,12 +316,10 @@ void file_events_example(){
|
|||||||
handlers.before_open = [](spdlog::filename_t filename) {
|
handlers.before_open = [](spdlog::filename_t filename) {
|
||||||
spdlog::info("Before opening {}", filename);
|
spdlog::info("Before opening {}", filename);
|
||||||
};
|
};
|
||||||
handlers.after_open = [](spdlog::filename_t filename, std::FILE *fstream) {
|
handlers.after_open = [](spdlog::filename_t filename, std::FILE *fstream) {
|
||||||
spdlog::info("After opening {}", filename);
|
|
||||||
fputs("After opening\n", fstream);
|
fputs("After opening\n", fstream);
|
||||||
};
|
};
|
||||||
handlers.before_close = [](spdlog::filename_t filename, std::FILE *fstream) {
|
handlers.before_close = [](spdlog::filename_t filename, std::FILE *fstream) {
|
||||||
spdlog::info("Before closing {}", filename);
|
|
||||||
fputs("Before closing\n", fstream);
|
fputs("Before closing\n", fstream);
|
||||||
};
|
};
|
||||||
handlers.after_close = [](spdlog::filename_t filename) {
|
handlers.after_close = [](spdlog::filename_t filename) {
|
||||||
|
Loading…
Reference in New Issue
Block a user