MCPcopy Create free account
hub / github.com/coreboot/coreboot / print_sub_command_usage

Function print_sub_command_usage

util/smmstoretool/main.c:91–107  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

89}
90
91static void print_sub_command_usage(const char sub_command[])
92{
93 fprintf(stderr, "\n");
94 fprintf(stderr, USAGE_FMT, program_name, program_name);
95 fprintf(stderr, "\n");
96
97 for (int i = 0; i < sub_command_count; ++i) {
98 const struct subcommand_t *cmd = &sub_commands[i];
99 if (!str_eq(cmd->name, sub_command))
100 continue;
101
102 cmd->print_help(stderr, cmd);
103 break;
104 }
105
106 exit(EXIT_FAILURE);
107}
108
109static void print_help(void)
110{

Callers 6

process_setFunction · 0.85
process_listFunction · 0.85
process_getFunction · 0.85
process_helpFunction · 0.85
process_removeFunction · 0.85
process_guidsFunction · 0.85

Calls 3

fprintfFunction · 0.85
str_eqFunction · 0.85
exitFunction · 0.85

Tested by

no test coverage detected