Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | tests: Fix a memory leak. | NIIBE Yutaka | 2019-05-14 | 1 | -0/+1 |
| | | | | | | | | | * tests/t-logging.c (check_log_info): Free LOGBUF. -- GnuPG-bug-id: 4498 Signed-off-by: NIIBE Yutaka <[email protected]> | ||||
* | logging: Escape controls in string arguments of log_ functions. | Werner Koch | 2018-12-06 | 1 | -0/+32 |
| | | | | | | | | | | | | | | | | * src/logging.c (struct fmt_string_filter_s): New. (fmt_string_filter): New. (_gpgrt_logv_internal): Use the filter. -- This change has two advantages: a) There is no more need to first escape string arguments before passing them to a log function and b) you can't forget to do the escaping and thus attacks using diagnostic output to trick out users won't work. The drawback is that you see \n instead of a real LF and under Windows the backslash in file names are doubled. Signed-off-by: Werner Koch <[email protected]> | ||||
* | core: Allow logging to an estream. | Werner Koch | 2018-12-05 | 1 | -0/+217 |
* src/logging.c (set_file_fd): Add and use new arg 'stream'. (_gpgrt_log_set_sink): Implement setting an estream sink. * tests/t-logging.c: New test. * tests/Makefile.am (TESTS): Add test. Signed-off-by: Werner Koch <[email protected]> |