commit | 7c72df5a95174c21bdc4ca09cd15a88c0c10e568 | [log] [tgz] |
---|---|---|
author | Ivan Delalande <colona@arista.com> | Fri Oct 06 16:48:19 2017 -0700 |
committer | Stephen Hemminger <stephen@networkplumber.org> | Wed Oct 11 11:04:47 2017 -0700 |
tree | 5f36247552a86257ed843130c0db91c18ad6a072 | |
parent | 4f6b73380d2c84b98b7beffe6ca73f635ab72a06 [diff] |
utils: add print_escape_buf to format and print arbitrary bytes Keep it as simple as possible for now: just escape anything that is not isprint-able, is among the "escape" parameter or '\' as an octal escape sequence. This should be pretty easy to extend if any other user needs something more complex in the future. Signed-off-by: Ivan Delalande <colona@arista.com>