diff options
Diffstat (limited to '')
-rw-r--r-- | common/miscellaneous.c | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/common/miscellaneous.c b/common/miscellaneous.c index 396f7224f..01d8c97be 100644 --- a/common/miscellaneous.c +++ b/common/miscellaneous.c @@ -117,23 +117,22 @@ print_fname_stdin (const char *s) return s; } -/* fixme: Globally replace it by print_sanitized_buffer. */ -void -print_string( FILE *fp, const byte *p, size_t n, int delim ) -{ - print_sanitized_buffer (fp, p, n, delim); -} void -print_utf8_string2 ( FILE *fp, const byte *p, size_t n, int delim ) +print_utf8_buffer2 (estream_t stream, const void *p, size_t n, int delim) { - print_sanitized_utf8_buffer (fp, p, n, delim); + char tmp[2]; + + tmp[0] = delim; + tmp[1] = 0; + es_write_sanitized_utf8_buffer (stream, p, n, tmp, NULL); } + void -print_utf8_string( FILE *fp, const byte *p, size_t n ) +print_utf8_buffer (estream_t stream, const void *p, size_t n) { - print_utf8_string2 (fp, p, n, 0); + es_write_sanitized_utf8_buffer (stream, p, n, NULL, NULL); } /* Write LENGTH bytes of BUFFER to FP as a hex encoded string. |