[v2] abilint: fix trivial typo when using abilint

Message ID 20211029014129.6641-1-tangmeng@uniontech.com
State New
Headers
Series [v2] abilint: fix trivial typo when using abilint |

Commit Message

tangmeng Oct. 29, 2021, 1:41 a.m. UTC
  When using the abilint command, several problems were found:
1.When abilint prints its version information, it does not terminate
it with a newline.
2.There is a spelling error, the path is mistakenly written as patch.
3.There are extra fields in the help option.
4.Inappropriate and confusing option description.

        * tools/abilint.cc (display_usage): Correct the errors and
        redundant content in the help information.
        (main): Add a newline after version string.

Signed-off-by: tangmeng <tangmeng@uniontech.com>
---
 tools/abilint.cc | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
  

Comments

Dodji Seketeli Nov. 2, 2021, 9:14 a.m. UTC | #1
Hello,

tangmeng <tangmeng@uniontech.com> a écrit:

> When using the abilint command, several problems were found:
> 1.When abilint prints its version information, it does not terminate
> it with a newline.
> 2.There is a spelling error, the path is mistakenly written as patch.
> 3.There are extra fields in the help option.
> 4.Inappropriate and confusing option description.
>
>         * tools/abilint.cc (display_usage): Correct the errors and
>         redundant content in the help information.
>         (main): Add a newline after version string.
>
> Signed-off-by: tangmeng <tangmeng@uniontech.com>

Applied to the master branch, thanks!

Cheers,

[...]
  

Patch

diff --git a/tools/abilint.cc b/tools/abilint.cc
index 856f935d..b82543d2 100644
--- a/tools/abilint.cc
+++ b/tools/abilint.cc
@@ -90,15 +90,14 @@  display_usage(const string& prog_name, ostream& out)
     << "  --help  display this message\n"
     << "  --version|-v  display program version information and exit\n"
     << "  --debug-info-dir <path> the path under which to look for "
-    << "  --headers-dir|--hd <patch> the path to headers of the elf file\n"
     "debug info for the elf <abi-file>\n"
+    << "  --headers-dir|--hd <path> the path to headers of the elf file\n"
     << "  --header-file|--hf <path> the path to one header of the elf file\n"
-    "debug info for the elf <abi-file>\n"
     << "  --suppressions|--suppr <path> specify a suppression file\n"
     << "  --diff  for xml inputs, perform a text diff between "
     "the input and the memory model saved back to disk\n"
     << "  --noout  do not display anything on stdout\n"
-    << "  --stdin|--  read abi-file content from stdin\n"
+    << "  --stdin  read abi-file content from stdin\n"
     << "  --tu  expect a single translation unit file\n";
 }
 
@@ -262,7 +261,8 @@  main(int argc, char* argv[])
   if (opts.display_version)
     {
       emit_prefix(argv[0], cout)
-	<< abigail::tools_utils::get_library_version_string();
+	<< abigail::tools_utils::get_library_version_string()
+	<< "\n";
       return 0;
     }