[Zrouter-src-freebsd] ZRouter.org: push to FreeBSD HEAD tree

zrouter-src-freebsd at zrouter.org zrouter-src-freebsd at zrouter.org
Wed Feb 1 10:56:59 UTC 2012


details:   http://zrouter.org/hg/FreeBSD/head//rev/e175097c7513
changeset: 324:e175097c7513
user:      ray at terran.dlink.ua
date:      Wed Feb 01 11:55:53 2012 +0200
description:
Update bin/sh

diffstat:

 head/bin/sh/arith_yacc.c  |   5 ++-
 head/bin/sh/arith_yylex.c |   4 +-
 head/bin/sh/eval.c        |   7 ++++-
 head/bin/sh/exec.c        |   4 +-
 head/bin/sh/funcs/kill    |  49 -----------------------------------------------
 head/bin/sh/histedit.c    |   5 +--
 head/bin/sh/jobs.c        |   3 +-
 7 files changed, 16 insertions(+), 61 deletions(-)

diffs (205 lines):

diff -r 447c2b301507 -r e175097c7513 head/bin/sh/arith_yacc.c
--- a/head/bin/sh/arith_yacc.c	Wed Feb 01 11:55:32 2012 +0200
+++ b/head/bin/sh/arith_yacc.c	Wed Feb 01 11:55:53 2012 +0200
@@ -33,7 +33,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: head/bin/sh/arith_yacc.c 227369 2011-11-08 23:54:39Z jilles $");
+__FBSDID("$FreeBSD: head/bin/sh/arith_yacc.c 230530 2012-01-25 08:42:19Z charnier $");
 
 #include <limits.h>
 #include <errno.h>
@@ -84,6 +84,8 @@
 
 #define ARITH_MAX_PREC 8
 
+int letcmd(int, char **);
+
 static __dead2 void yyerror(const char *s)
 {
 	error("arithmetic expression: %s: \"%s\"", s, arith_startbuf);
@@ -377,4 +379,3 @@
 	out1fmt(ARITH_FORMAT_STR "\n", i);
 	return !i;
 }
-
diff -r 447c2b301507 -r e175097c7513 head/bin/sh/arith_yylex.c
--- a/head/bin/sh/arith_yylex.c	Wed Feb 01 11:55:32 2012 +0200
+++ b/head/bin/sh/arith_yylex.c	Wed Feb 01 11:55:53 2012 +0200
@@ -33,7 +33,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD$");
+__FBSDID("$FreeBSD: head/bin/sh/arith_yylex.c 230530 2012-01-25 08:42:19Z charnier $");
 
 #include <inttypes.h>
 #include <stdlib.h>
@@ -53,7 +53,7 @@
 extern const char *arith_buf;
 
 int
-yylex()
+yylex(void)
 {
 	int value;
 	const char *buf = arith_buf;
diff -r 447c2b301507 -r e175097c7513 head/bin/sh/eval.c
--- a/head/bin/sh/eval.c	Wed Feb 01 11:55:32 2012 +0200
+++ b/head/bin/sh/eval.c	Wed Feb 01 11:55:53 2012 +0200
@@ -36,7 +36,7 @@
 #endif
 #endif /* not lint */
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: head/bin/sh/eval.c 230212 2012-01-16 11:07:46Z dumbbell $");
+__FBSDID("$FreeBSD: head/bin/sh/eval.c 230463 2012-01-22 14:00:33Z jilles $");
 
 #include <paths.h>
 #include <signal.h>
@@ -348,6 +348,7 @@
 	union node *argp;
 	struct strlist *sp;
 	struct stackmark smark;
+	int status;
 
 	setstackmark(&smark);
 	arglist.lastp = &arglist.list;
@@ -357,11 +358,12 @@
 	}
 	*arglist.lastp = NULL;
 
-	exitstatus = 0;
 	loopnest++;
+	status = 0;
 	for (sp = arglist.list ; sp ; sp = sp->next) {
 		setvar(n->nfor.var, sp->text, 0);
 		evaltree(n->nfor.body, flags);
+		status = exitstatus;
 		if (evalskip) {
 			if (evalskip == SKIPCONT && --skipcount <= 0) {
 				evalskip = 0;
@@ -374,6 +376,7 @@
 	}
 	loopnest--;
 	popstackmark(&smark);
+	exitstatus = status;
 }
 
 
diff -r 447c2b301507 -r e175097c7513 head/bin/sh/exec.c
--- a/head/bin/sh/exec.c	Wed Feb 01 11:55:32 2012 +0200
+++ b/head/bin/sh/exec.c	Wed Feb 01 11:55:53 2012 +0200
@@ -36,7 +36,7 @@
 #endif
 #endif /* not lint */
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: head/bin/sh/exec.c 229220 2012-01-01 22:17:12Z jilles $");
+__FBSDID("$FreeBSD: head/bin/sh/exec.c 230530 2012-01-25 08:42:19Z charnier $");
 
 #include <sys/types.h>
 #include <sys/stat.h>
@@ -493,7 +493,7 @@
  */
 
 void
-changepath(const char *newval)
+changepath(const char *newval __unused)
 {
 	clearcmdentry();
 }
diff -r 447c2b301507 -r e175097c7513 head/bin/sh/funcs/kill
--- a/head/bin/sh/funcs/kill	Wed Feb 01 11:55:32 2012 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,49 +0,0 @@
-#!/bin/sh
-
-#-
-# Copyright (c) 1991, 1993
-#	The Regents of the University of California.  All rights reserved.
-#
-# This code is derived from software contributed to Berkeley by
-# Kenneth Almquist.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-# 1. Redistributions of source code must retain the above copyright
-#    notice, this list of conditions and the following disclaimer.
-# 2. Redistributions in binary form must reproduce the above copyright
-#    notice, this list of conditions and the following disclaimer in the
-#    documentation and/or other materials provided with the distribution.
-# 4. Neither the name of the University nor the names of its contributors
-#    may be used to endorse or promote products derived from this software
-#    without specific prior written permission.
-#
-# THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-# SUCH DAMAGE.
-#
-#	@(#)kill	8.2 (Berkeley) 5/4/95
-# $FreeBSD$
-
-# Convert job names to process ids and then run /bin/kill.
-
-kill() {
-	local args x
-	args=
-	for x in "$@"
-	do	case $x in
-		%*)	x=`jobid "$x"` ;;
-		esac
-		args="$args $x"
-	done
-	/bin/kill $args
-}
diff -r 447c2b301507 -r e175097c7513 head/bin/sh/histedit.c
--- a/head/bin/sh/histedit.c	Wed Feb 01 11:55:32 2012 +0200
+++ b/head/bin/sh/histedit.c	Wed Feb 01 11:55:53 2012 +0200
@@ -36,7 +36,7 @@
 #endif
 #endif /* not lint */
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: head/bin/sh/histedit.c 229220 2012-01-01 22:17:12Z jilles $");
+__FBSDID("$FreeBSD: head/bin/sh/histedit.c 230530 2012-01-25 08:42:19Z charnier $");
 
 #include <sys/param.h>
 #include <limits.h>
@@ -160,8 +160,7 @@
 
 
 void
-sethistsize(hs)
-	const char *hs;
+sethistsize(const char *hs)
 {
 	int histsize;
 	HistEvent he;
diff -r 447c2b301507 -r e175097c7513 head/bin/sh/jobs.c
--- a/head/bin/sh/jobs.c	Wed Feb 01 11:55:32 2012 +0200
+++ b/head/bin/sh/jobs.c	Wed Feb 01 11:55:53 2012 +0200
@@ -36,7 +36,7 @@
 #endif
 #endif /* not lint */
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: head/bin/sh/jobs.c 223060 2011-06-13 21:03:27Z jilles $");
+__FBSDID("$FreeBSD: head/bin/sh/jobs.c 230530 2012-01-25 08:42:19Z charnier $");
 
 #include <sys/ioctl.h>
 #include <sys/param.h>
@@ -92,6 +92,7 @@
 #endif
 static void freejob(struct job *);
 static struct job *getjob(char *);
+pid_t getjobpgrp(char *);
 static pid_t dowait(int, struct job *);
 static pid_t waitproc(int, int *);
 static void checkzombies(void);


More information about the Zrouter-src-freebsd mailing list