liblog: logcat: Add printable format modifier

- added printable format modifier:
  logcat -v printable
- opencoded borrowed individual utf8 validity checking algorithm
  from utf8_length() in libutils/Unicode.cpp
- if considered basic one-character ASCII, use popular \x escape
  sequences for non-printable
- logprint convert to C comments to drop mixed-mode

Bug: 19000361
Change-Id: I122a5b8fb41216fc0bc816178c0b768f3df56586
2 files changed
tree: 2fe38da8f77c835c66294e0eac59a445eb4fdf9e
  1. liblog/
  2. logcat/
  3. logd/
  4. logwrapper/