Skip to content

Commit

Permalink
readpublic
Browse files Browse the repository at this point in the history
Signed-off-by: Bill Roberts <[email protected]>
  • Loading branch information
williamcroberts committed Dec 8, 2023
1 parent 5f73e1e commit 5aa45ed
Show file tree
Hide file tree
Showing 6 changed files with 130 additions and 108 deletions.
3 changes: 3 additions & 0 deletions lib/tpm2_options.c
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,7 @@ tpm2_option_code tpm2_handle_options(int argc, char **argv,
{ "quiet", no_argument, NULL, 'Q' },
{ "version", no_argument, NULL, 'v' },
{ "enable-errata", no_argument, NULL, 'Z' },
{ "canonical", no_argument, NULL, 42 }
};


Expand Down Expand Up @@ -387,6 +388,8 @@ tpm2_option_code tpm2_handle_options(int argc, char **argv,
case '?':
rc = tpm2_option_code_err;
goto out;
case 42:
flags->canonical = 1;
default:
/* NULL on_opt handler and unknown option specified is an error */
if (!tool_opts || !tool_opts->callbacks.on_opt) {
Expand Down
2 changes: 1 addition & 1 deletion lib/tpm2_options.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ union tpm2_option_flags {
uint8_t quiet :1;
uint8_t enable_errata :1;
uint8_t tcti_none :1;
//uint8_t no_output :1;
uint8_t canonical :1;
};
uint8_t all;
};
Expand Down
Loading

0 comments on commit 5aa45ed

Please sign in to comment.