]> git.ipfire.org Git - thirdparty/iproute2.git/commitdiff
ip: document exit code
authorStephen Hemminger <shemming@brocade.com>
Wed, 6 May 2015 16:47:22 +0000 (09:47 -0700)
committerStephen Hemminger <shemming@brocade.com>
Thu, 7 May 2015 15:11:28 +0000 (08:11 -0700)
The ip command has always had a consistent exit status
document it so that developers see it.

man/man8/ip.8

index 43ddac9134dba2ff58c339f3b8fc6cc4d3c72e0b..045414dd52150d41cfef937c6914ea0839e95ee4 100644 (file)
@@ -245,7 +245,7 @@ Use color output.
 
 .PP
 The names of all objects may be written in full or
-abbreviated form, for exampe
+abbreviated form, for example
 .B address
 can be abbreviated as
 .B addr
@@ -275,6 +275,10 @@ Usually it is
 or, if the objects of this class cannot be listed,
 .BR "help" .
 
+.SH EXIT STATUS
+Exit status is 0 if command was successful, and 1 if there is a syntax error.
+If an error was reported by the kernel exit status is 2.
+
 .SH HISTORY
 .B ip
 was written by Alexey N. Kuznetsov and added in Linux 2.2.