xxd: implement -i "C style output"

function                                             old     new   delta
xxd_main                                             710     888    +178
.rodata                                           103252  103331     +79
print_C_style                                          -      78     +78
packed_usage                                       33639   33652     +13
next                                                 276     278      +2
------------------------------------------------------------------------------
(add/remove: 1/0 grow/shrink: 4/0 up/down: 350/0)             Total: 350 bytes

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Denys Vlasenko
2021-06-18 00:59:17 +02:00
parent 25fe2d50bd
commit 2c436679fb
3 changed files with 53 additions and 26 deletions

View File

@ -34,6 +34,7 @@ typedef struct dumper_t {
smallint dump_vflag; /*enum dump_vflag_t*/
FS *fshead;
const char *xxd_eofstring;
off_t address; /* address/offset in stream */
long long xxd_displayoff;
} dumper_t;