Add man page
This commit is contained in:
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
* This file is part of patchelfcrc.
|
||||
* Copyright (c) 2022 Mario Hüttel.
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, version 2 only.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
|
||||
#include <patchelfcrc/elfpatch.h>
|
||||
#include <patchelfcrc/reporting.h>
|
||||
#include <unistd.h>
|
||||
|
10
src/main.c
10
src/main.c
@@ -373,6 +373,11 @@ int main(int argc, char **argv)
|
||||
reporting_enable_verbose();
|
||||
print_verbose_start_info(&cmd_opts);
|
||||
|
||||
if (cmd_opts.list) {
|
||||
list_predefined_crcs();
|
||||
goto free_cmds;
|
||||
}
|
||||
|
||||
/* Check if file has been supplied */
|
||||
if (!cmd_opts.elf_path) {
|
||||
print_err("No ELF file specified. Exiting...\n");
|
||||
@@ -383,11 +388,6 @@ int main(int argc, char **argv)
|
||||
print_err("No output section specified. Will continue but not patch file.\n");
|
||||
}
|
||||
|
||||
if (cmd_opts.list) {
|
||||
list_predefined_crcs();
|
||||
goto free_cmds;
|
||||
}
|
||||
|
||||
/* Do error printing if using a reversed polynomial. It is not implemented yet! */
|
||||
if (cmd_opts.crc.rev) {
|
||||
print_err("Reversed polynomials are not supported yet\nExiting...\n");
|
||||
|
Reference in New Issue
Block a user