aboutsummaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorJoerg Wunsch <joerg@FreeBSD.org>1995-10-01 15:11:42 +0000
committerJoerg Wunsch <joerg@FreeBSD.org>1995-10-01 15:11:42 +0000
commit6d753bdd672506f291807941a290e8b900fad08b (patch)
tree1078fd60f95fb90ce724202147f6c60b574737e2 /bin
parent5dde8b2750ee970a26326a431f4d7eed5800cf84 (diff)
Notes
Diffstat (limited to 'bin')
-rw-r--r--bin/sh/options.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/bin/sh/options.c b/bin/sh/options.c
index 92e04caa25bd..de6f60ce7fb9 100644
--- a/bin/sh/options.c
+++ b/bin/sh/options.c
@@ -33,7 +33,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: options.c,v 1.3 1995/05/30 00:07:21 rgrimes Exp $
+ * $Id: options.c,v 1.4 1995/08/06 19:35:33 joerg Exp $
*/
#ifndef lint
@@ -106,6 +106,9 @@ procargs(argc, argv)
commandname = arg0 = *argptr++;
setinputfile(commandname, 0);
}
+ if (minusc)
+ /* Posix.2: first arg after -c cmd is $0, remainder $1... */
+ arg0 = *argptr++;
shellparam.p = argptr;
/* assert(shellparam.malloc == 0 && shellparam.nparam == 0); */
while (*argptr) {