Commit Graph

5 Commits

Author SHA1 Message Date
Yuxuan Shui 6f0daf8076
Add a writev interface for log targets
So some log targets can be more efficient and allocate less memory.

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
2018-12-20 04:45:07 +00:00
Yuxuan Shui 185c0ce97c
Guard log_printf in LOG macros with a log level check
So that the format arguments will only be evaluated if the log is
enabled by the log level. Allow us to add more expensive logs without
impact performance when they are not enabled.

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
2018-12-20 02:34:45 +00:00
Yuxuan Shui fc57c7b55b
Add a FATAL ERROR log level
For errors that cause compton to quit

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
2018-12-20 02:02:08 +00:00
Yuxuan Shui d9409ae2c9
Add command line and config file option log-level
Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
2018-12-20 01:26:04 +00:00
Yuxuan Shui 1bcd7f2f7a
Add a simple logging framework
It's not very pretty now, but it will get better.

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
2018-12-20 01:02:56 +00:00