diff options
author | Douglas Gilbert <dgilbert@interlog.com> | 2021-11-20 17:13:42 +0000 |
---|---|---|
committer | Douglas Gilbert <dgilbert@interlog.com> | 2021-11-20 17:13:42 +0000 |
commit | 20315aa4fae1340e5d4b1faae15b90ee34b9ea50 (patch) | |
tree | eb935ed0b6aed4abf787556adcfe9e3cb99c297d /lib/sg_lib.c | |
parent | 26be8550ae1aad5db9bcf9b0cfe1fdecccd210df (diff) | |
download | sg3_utils-20315aa4fae1340e5d4b1faae15b90ee34b9ea50.tar.gz |
sg_z_act_query: new utility for sending either a Zone activate or Zone query command; sg_rep_zones: add Report zone starting LBA granularity field in REPORT ZONES response [zbc2r12]; sg_decode_sense: add --nodecode option; initialize all sense buffers to 0; rework main README file
git-svn-id: https://svn.bingwo.ca/repos/sg3_utils/trunk@923 6180dd3e-e324-4e3e-922d-17de1ae2f315
Diffstat (limited to 'lib/sg_lib.c')
-rw-r--r-- | lib/sg_lib.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/sg_lib.c b/lib/sg_lib.c index 8884379a..35f0fbdd 100644 --- a/lib/sg_lib.c +++ b/lib/sg_lib.c @@ -2818,13 +2818,14 @@ trimTrailingSpaces(char * b) b[k + 1] = '\0'; } -/* Note the ASCII-hex output goes to stdout. [Most other output from functions - * in this file go to sg_warnings_strm (default stderr).] - * 'no_ascii' allows for 3 output types: +/* Read binary starting at 'str' for 'len' bytes and output as ASCII + * hexadecinal into file pointer (fp). 16 bytes per line are output with an + * additional space between 8th and 9th byte on each line (for readability). + * 'no_ascii' selects one of 3 output format types: * > 0 each line has address then up to 16 ASCII-hex bytes * = 0 in addition, the bytes are listed in ASCII to the right * < 0 only the ASCII-hex bytes are listed (i.e. without address) */ -static void +void dStrHexFp(const char* str, int len, int no_ascii, FILE * fp) { const char * p = str; |