Skip to content

Commit

Permalink
Tools: fix JSON misspelling in cbordump
Browse files Browse the repository at this point in the history
Signed-off-by: Nicolas Iooss <nicolas.iooss@ledger.fr>
  • Loading branch information
niooss-ledger authored and thiagomacieira committed Feb 12, 2023
1 parent cd3cfc3 commit 9c57e53
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tools/cbordump/cbordump.c
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ void printerror(CborError err, const char *fname)
exit(EXIT_FAILURE);
}

void dumpFile(FILE *in, const char *fname, bool printJosn, int flags)
void dumpFile(FILE *in, const char *fname, bool printJson, int flags)
{
static const size_t chunklen = 16 * 1024;
static size_t bufsize = 0;
Expand All @@ -72,7 +72,7 @@ void dumpFile(FILE *in, const char *fname, bool printJosn, int flags)
CborValue value;
CborError err = cbor_parser_init(buffer, buflen, 0, &parser, &value);
if (!err) {
if (printJosn)
if (printJson)
err = cbor_value_to_json_advance(stdout, &value, flags);
else
err = cbor_value_to_pretty_advance_flags(stdout, &value, flags);
Expand Down

0 comments on commit 9c57e53

Please sign in to comment.