From a68fbc44ee3cefd6c15abe9d3a343b4e96580aa3 Mon Sep 17 00:00:00 2001 From: Jilles Tjoelker Date: Sun, 7 Jun 2009 15:04:43 +0000 Subject: [PATCH] Mention the range for the exit status for the exit special builtin. The exit status may exceed 255 in some cases (return); even though it seems unwise to rely on this, it is also unwise to assume that $? is always between 0 and 255. This resolves bin/124748 by documenting that 'exit -1' is not valid. PR: bin/124748 Approved by: ed (mentor) --- bin/sh/sh.1 | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/sh/sh.1 b/bin/sh/sh.1 index cc8874e4e40f..d3ae24fe8d93 100644 --- a/bin/sh/sh.1 +++ b/bin/sh/sh.1 @@ -1682,6 +1682,7 @@ If is given it is used as the exit status of the shell; otherwise the exit status of the preceding command is used. +The exit status should be an integer between 0 and 255. .It Ic export Ar name ... .It Ic export Op Fl p The specified names are exported so that they will