svn commit: r295937 - in head/bin/sh: . tests/parser

2016-02-23 Thread Jilles Tjoelker
Author: jilles Date: Tue Feb 23 22:44:01 2016 New Revision: 295937 URL: https://svnweb.freebsd.org/changeset/base/295937 Log: sh: Fix set -v and multiline history after r295825. r295825 erroneously dropped the newline from the input data for 'set -v' output and multiline history.

svn commit: r295868 - head/bin/sh

2016-02-21 Thread Jilles Tjoelker
Author: jilles Date: Sun Feb 21 20:58:24 2016 New Revision: 295868 URL: https://svnweb.freebsd.org/changeset/base/295868 Log: sh: Don't hash alias name when there are no aliases. Modified: head/bin/sh/alias.c Modified: head/bin/sh/alias.c

svn commit: r295866 - head/bin/sh

2016-02-21 Thread Jilles Tjoelker
Author: jilles Date: Sun Feb 21 18:54:17 2016 New Revision: 295866 URL: https://svnweb.freebsd.org/changeset/base/295866 Log: sh: Optimize setprompt(0). Avoid doing work to print an empty prompt (such as when reading scripts). Modified: head/bin/sh/parser.c Modified:

svn commit: r295862 - head/bin/sh

2016-02-21 Thread Jilles Tjoelker
Author: jilles Date: Sun Feb 21 16:48:37 2016 New Revision: 295862 URL: https://svnweb.freebsd.org/changeset/base/295862 Log: sh: Remove unnecessary flushouts while reading script. Output is flushed when a builtin is done or immediately after writing it (error messages, set -v output,

svn commit: r295825 - in head/bin/sh: . tests/parser

2016-02-19 Thread Jilles Tjoelker
Author: jilles Date: Fri Feb 19 21:53:12 2016 New Revision: 295825 URL: https://svnweb.freebsd.org/changeset/base/295825 Log: sh: Rework code to remove '\0' from shell input. This fixes bugs where '\0' was not removed correctly and speeds up the parser. Added:

svn commit: r295818 - head/bin/sh/tests/parser

2016-02-19 Thread Jilles Tjoelker
Author: jilles Date: Fri Feb 19 16:56:07 2016 New Revision: 295818 URL: https://svnweb.freebsd.org/changeset/base/295818 Log: sh: Add tests for comments in sh -c. Added: head/bin/sh/tests/parser/comment1.0 (contents, props changed) head/bin/sh/tests/parser/comment2.42 (contents, props

svn commit: r295384 - head/lib/libc/sys

2016-02-07 Thread Jilles Tjoelker
Author: jilles Date: Sun Feb 7 21:25:08 2016 New Revision: 295384 URL: https://svnweb.freebsd.org/changeset/base/295384 Log: semget(2): Add missing [EINVAL] conditions. PR: 206927 Modified: head/lib/libc/sys/semget.2 Modified: head/lib/libc/sys/semget.2

svn commit: r295385 - in head: sys/kern tools/regression/sysvsem

2016-02-07 Thread Jilles Tjoelker
Author: jilles Date: Sun Feb 7 22:12:39 2016 New Revision: 295385 URL: https://svnweb.freebsd.org/changeset/base/295385 Log: semget(): Check for [EEXIST] error first. Although POSIX literally permits failing with [EINVAL] if IPC_CREAT and IPC_EXCL were both passed, the semaphore set

svn commit: r295082 - head/bin/test

2016-01-30 Thread Jilles Tjoelker
Author: jilles Date: Sat Jan 30 19:59:58 2016 New Revision: 295082 URL: https://svnweb.freebsd.org/changeset/base/295082 Log: test: Optimize operator lookup. The linear search using strcmp() shows up in pmcstat for several percent. Split the operators into lengths and whether they

svn commit: r295085 - head/bin/sh

2016-01-30 Thread Jilles Tjoelker
Author: jilles Date: Sat Jan 30 21:21:25 2016 New Revision: 295085 URL: https://svnweb.freebsd.org/changeset/base/295085 Log: sh: Don't allocate a redirtab if there are no redirections. Builtins (including variable assignments without command word), function calls and redirected compound

svn commit: r295083 - head/bin/sh

2016-01-30 Thread Jilles Tjoelker
Author: jilles Date: Sat Jan 30 20:10:20 2016 New Revision: 295083 URL: https://svnweb.freebsd.org/changeset/base/295083 Log: sh(1): Document 'cd -'. This reflects the changes in r294649 and can therefore not be MFCed by itself. Modified: head/bin/sh/sh.1 Modified: head/bin/sh/sh.1

svn commit: r294667 - head/bin/sh

2016-01-24 Thread Jilles Tjoelker
Author: jilles Date: Sun Jan 24 17:01:34 2016 New Revision: 294667 URL: https://svnweb.freebsd.org/changeset/base/294667 Log: sh: Remove a global variable from cd.c. Modified: head/bin/sh/cd.c Modified: head/bin/sh/cd.c

svn commit: r294692 - head/bin/sh

2016-01-24 Thread Jilles Tjoelker
Author: jilles Date: Sun Jan 24 22:26:25 2016 New Revision: 294692 URL: https://svnweb.freebsd.org/changeset/base/294692 Log: sh: Constify internal representation in expand.c. Forbid (temporary or permanent) modifications of the strings in NARG nodes during expansion. Tilde

svn commit: r294649 - head/bin/sh

2016-01-23 Thread Jilles Tjoelker
Author: jilles Date: Sat Jan 23 23:00:38 2016 New Revision: 294649 URL: https://svnweb.freebsd.org/changeset/base/294649 Log: sh: Use OLDPWD shell variable for 'cd -'. Per POSIX, 'cd -' should use the OLDPWD shell variable, not internal state. This variable is normally exported.

svn commit: r294593 - in head/bin/sh: . tests/builtins

2016-01-22 Thread Jilles Tjoelker
Author: jilles Date: Fri Jan 22 20:10:08 2016 New Revision: 294593 URL: https://svnweb.freebsd.org/changeset/base/294593 Log: sh: Clean a readonly local, even if the variable does not exist outside. If a local variable has been made read-only, this should not prevent its removal when the

svn commit: r294582 - head/bin/sh/tests/builtins

2016-01-22 Thread Jilles Tjoelker
Author: jilles Date: Fri Jan 22 18:10:36 2016 New Revision: 294582 URL: https://svnweb.freebsd.org/changeset/base/294582 Log: sh: Add already working test for local-readonly interaction. Added: head/bin/sh/tests/builtins/local6.0 (contents, props changed) Modified:

svn commit: r294565 - in head: lib/libc/gen tools/regression/posixsem2

2016-01-22 Thread Jilles Tjoelker
Author: jilles Date: Fri Jan 22 14:52:31 2016 New Revision: 294565 URL: https://svnweb.freebsd.org/changeset/base/294565 Log: sem: Don't free nameinfo that is still in list when open() fails. This bug could be reproduced easily by calling sem_open() with O_CREAT | O_EXCL on a semaphore

svn commit: r294348 - head/bin/sh

2016-01-19 Thread Jilles Tjoelker
Author: jilles Date: Tue Jan 19 22:41:26 2016 New Revision: 294348 URL: https://svnweb.freebsd.org/changeset/base/294348 Log: sh: Simplify some code related to positional parameters. Modified: head/bin/sh/options.c head/bin/sh/options.h Modified: head/bin/sh/options.c

svn commit: r294234 - head/lib/libc/sys

2016-01-17 Thread Jilles Tjoelker
Author: jilles Date: Sun Jan 17 21:14:27 2016 New Revision: 294234 URL: https://svnweb.freebsd.org/changeset/base/294234 Log: utimensat(2): Correct description of [EINVAL] error. MFC after:4 days Modified: head/lib/libc/sys/utimensat.2 Modified: head/lib/libc/sys/utimensat.2

Re: svn commit: r293783 - head/lib/libc/sys

2016-01-13 Thread Jilles Tjoelker
On Wed, Jan 13, 2016 at 08:58:12AM -0800, John Baldwin wrote: > On Tuesday, January 12, 2016 08:53:57 PM Jilles Tjoelker wrote: > > Author: jilles > > Date: Tue Jan 12 20:53:57 2016 > > New Revision: 293783 > > URL: https://svnweb.freebsd.org/changeset/base/293783 >

svn commit: r293783 - head/lib/libc/sys

2016-01-12 Thread Jilles Tjoelker
Author: jilles Date: Tue Jan 12 20:53:57 2016 New Revision: 293783 URL: https://svnweb.freebsd.org/changeset/base/293783 Log: Update futimens/utimensat for MFC to stable/10: * Fix __FreeBSD_version check. * Update history section in man page. An MFC of this commit to stable/10 will

svn commit: r293635 - in head/bin/sh: . tests/builtins

2016-01-10 Thread Jilles Tjoelker
Author: jilles Date: Sun Jan 10 16:31:28 2016 New Revision: 293635 URL: https://svnweb.freebsd.org/changeset/base/293635 Log: sh: Update associated state when restoring locals while leaving a function. Some variables like PATH call a function when modified. Make sure to call this also

svn commit: r293392 - head/bin/sh

2016-01-07 Thread Jilles Tjoelker
Author: jilles Date: Thu Jan 7 23:13:20 2016 New Revision: 293392 URL: https://svnweb.freebsd.org/changeset/base/293392 Log: sh: Reduce size of options table. Modified: head/bin/sh/expand.c head/bin/sh/options.c head/bin/sh/options.h head/bin/sh/var.c Modified: head/bin/sh/expand.c

svn commit: r293359 - in head/bin/sh: . tests/builtins

2016-01-07 Thread Jilles Tjoelker
Author: jilles Date: Thu Jan 7 20:48:24 2016 New Revision: 293359 URL: https://svnweb.freebsd.org/changeset/base/293359 Log: sh: Ensure OPTIND=1 in subshell without forking does not affect outer env. Command substitutions containing a single simple command and here-document expansion

svn commit: r293371 - head/bin/sh/tests/builtins

2016-01-07 Thread Jilles Tjoelker
Author: jilles Date: Thu Jan 7 21:46:07 2016 New Revision: 293371 URL: https://svnweb.freebsd.org/changeset/base/293371 Log: sh: Add a test for 'cd -'. Redirect 'cd -' output to /dev/null since POSIX requires it to write the new directory name even if not interactive, but we currently

svn commit: r293204 - in head: include lib/libc/gen usr.sbin/cron/crontab

2016-01-05 Thread Jilles Tjoelker
Author: jilles Date: Tue Jan 5 16:21:20 2016 New Revision: 293204 URL: https://svnweb.freebsd.org/changeset/base/293204 Log: Add sbin and /usr/local directories to _PATH_DEFPATH. Set _PATH_DEFPATH to /sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin. This is the path in the

Re: svn commit: r293115 - head/etc

2016-01-04 Thread Jilles Tjoelker
sh does not source any startup files. Login shells source /etc/profile and ~/.profile and interactive shells source the file whose name is in the ENV environment variable. The prompt comes from trying to remove an existing file which is not writable. It can be supp

svn commit: r293118 - head/bin/sh

2016-01-03 Thread Jilles Tjoelker
Author: jilles Date: Sun Jan 3 21:30:22 2016 New Revision: 293118 URL: https://svnweb.freebsd.org/changeset/base/293118 Log: sh: Reduce size of builtins table. Modified: head/bin/sh/exec.c head/bin/sh/mkbuiltins Modified: head/bin/sh/exec.c

svn commit: r293002 - head/bin/sh

2015-12-31 Thread Jilles Tjoelker
Author: jilles Date: Thu Dec 31 20:15:57 2015 New Revision: 293002 URL: https://svnweb.freebsd.org/changeset/base/293002 Log: sh: Remove redundant CTLQUOTEMARK checks. With the new expand.c code, the intermediate representation passed to the pathname generation code only contains CTLESC,

svn commit: r292991 - head/bin/sh

2015-12-31 Thread Jilles Tjoelker
. * Copyright (c) 1997-2005 * Herbert Xu <herb...@gondor.apana.org.au>. All rights reserved. + * Copyright (c) 2010-2015 + * Jilles Tjoelker <jil...@stack.nl>. All rights reserved. * * This code is derived from software contributed to Berkeley by * Kenneth Almquist. @@ -

svn commit: r292995 - head/bin/sh

2015-12-31 Thread Jilles Tjoelker
Author: jilles Date: Thu Dec 31 18:56:11 2015 New Revision: 292995 URL: https://svnweb.freebsd.org/changeset/base/292995 Log: sh: Reindent expandmeta(). Modified: head/bin/sh/expand.c Modified: head/bin/sh/expand.c

svn commit: r292994 - head/bin/sh

2015-12-31 Thread Jilles Tjoelker
Author: jilles Date: Thu Dec 31 18:47:54 2015 New Revision: 292994 URL: https://svnweb.freebsd.org/changeset/base/292994 Log: sh: Perform pathname generation during the first expansion phases. This avoids the need to add and remove CTLESC bytes if pathname generation will not be

svn commit: r292887 - head/bin/sh

2015-12-29 Thread Jilles Tjoelker
Author: jilles Date: Tue Dec 29 20:51:29 2015 New Revision: 292887 URL: https://svnweb.freebsd.org/changeset/base/292887 Log: sh: Split subevalvar() in #/##/%/%% and =/? parts. Modified: head/bin/sh/expand.c Modified: head/bin/sh/expand.c

svn commit: r292758 - head/bin/sh/tests/expansion

2015-12-26 Thread Jilles Tjoelker
Author: jilles Date: Sat Dec 26 22:27:48 2015 New Revision: 292758 URL: https://svnweb.freebsd.org/changeset/base/292758 Log: sh: Add tests for #/##/%/%% on $* and $@. Although POSIX leaves things like ${*#X} unspecified, it occasionally occurs in practice. Add some tests that seem to

Re: svn commit: r290197 - in head: etc/defaults etc/rc.d sys/kern

2015-12-21 Thread Jilles Tjoelker
done > + mount -a -t ${mount_excludes} > + err=$? > + fi > + > check_startmsgs && echo '.' > > case ${err} in > @@ -44,7 +78,7 @@ mountcritlocal_start() > ;; > *) > echo 'Mounting /etc/fstab file

svn commit: r292521 - in head/lib/libc: gen iconv net

2015-12-20 Thread Jilles Tjoelker
Author: jilles Date: Sun Dec 20 23:05:20 2015 New Revision: 292521 URL: https://svnweb.freebsd.org/changeset/base/292521 Log: libc: Use namespace.h in a few more files. libc now no longer calls fstat(), socketpair() and wait(), only the underscore-prefixed versions (_waitpid() instead of

svn commit: r292513 - head/lib/libc/sys

2015-12-20 Thread Jilles Tjoelker
Author: jilles Date: Sun Dec 20 15:11:11 2015 New Revision: 292513 URL: https://svnweb.freebsd.org/changeset/base/292513 Log: clock_gettime(2),gettimeofday(2): Remove [EFAULT] error. Depending on system configuration and parameters, clock_gettime() and gettimeofday() may not be system

svn commit: r292517 - head/bin/sh

2015-12-20 Thread Jilles Tjoelker
Author: jilles Date: Sun Dec 20 16:40:36 2015 New Revision: 292517 URL: https://svnweb.freebsd.org/changeset/base/292517 Log: sh/mknodes: Close files and check for errors when writing. This is a build tool only and does not affect run time. PR: 204951 MFC after:1 week

svn commit: r292516 - head/lib/libthr/thread

2015-12-20 Thread Jilles Tjoelker
Author: jilles Date: Sun Dec 20 16:33:56 2015 New Revision: 292516 URL: https://svnweb.freebsd.org/changeset/base/292516 Log: libthr: Don't use both __sys_open() and __sys_openat(). Modified: head/lib/libthr/thread/thr_init.c head/lib/libthr/thread/thr_private.h Modified:

svn commit: r292360 - head/bin/sh

2015-12-16 Thread Jilles Tjoelker
Author: jilles Date: Wed Dec 16 20:33:47 2015 New Revision: 292360 URL: https://svnweb.freebsd.org/changeset/base/292360 Log: sh: Fix use-after-free when attempting to modify a read-only variable. Reported by: bapt MFC after:1 week Modified: head/bin/sh/var.c Modified:

svn commit: r292130 - head/lib/libc/gen

2015-12-12 Thread Jilles Tjoelker
Author: jilles Date: Sat Dec 12 15:57:46 2015 New Revision: 292130 URL: https://svnweb.freebsd.org/changeset/base/292130 Log: exec(3): Fix COMPATIBILITY section: default path does not contain cwd. MFC after:1 week Modified: head/lib/libc/gen/exec.3 Modified:

svn commit: r291903 - head/bin/sh/tests/parameters

2015-12-06 Thread Jilles Tjoelker
Author: jilles Date: Sun Dec 6 14:09:31 2015 New Revision: 291903 URL: https://svnweb.freebsd.org/changeset/base/291903 Log: sh: Add limited test for ${#@} and ${#*}. POSIX leaves the result of expanding ${#@} and ${#*} unspecified, but ensure it is numeric. Added:

svn commit: r291857 - head/bin/sh/tests/parameters

2015-12-05 Thread Jilles Tjoelker
Author: jilles Date: Sat Dec 5 12:55:34 2015 New Revision: 291857 URL: https://svnweb.freebsd.org/changeset/base/291857 Log: sh: Link tests/parameters/positional8.0 to the build. This was forgotten in r291025. Modified: head/bin/sh/tests/parameters/Makefile Modified:

svn commit: r291770 - head/etc

2015-12-04 Thread Jilles Tjoelker
Author: jilles Date: Fri Dec 4 16:32:29 2015 New Revision: 291770 URL: https://svnweb.freebsd.org/changeset/base/291770 Log: rc.subr: Check for running daemons before a custom start_cmd is executed. Currently rc scripts implementing their own start_cmd do not enjoy the benefits of

svn commit: r291267 - head/bin/sh

2015-11-24 Thread Jilles Tjoelker
Author: jilles Date: Tue Nov 24 22:47:19 2015 New Revision: 291267 URL: https://svnweb.freebsd.org/changeset/base/291267 Log: sh: Remove global state from nodes.c. No functional change is intended. Modified: head/bin/sh/mknodes.c head/bin/sh/nodes.c.pat Modified:

svn commit: r291025 - in head/bin/sh: . tests/parameters

2015-11-18 Thread Jilles Tjoelker
Author: jilles Date: Wed Nov 18 21:09:03 2015 New Revision: 291025 URL: https://svnweb.freebsd.org/changeset/base/291025 Log: sh: Fix ""$@, which should not use the special case for "$@". "$@" should expand to no words if there are no positional parameters, but ""$@ should always expand

svn commit: r290515 - head/etc/defaults

2015-11-07 Thread Jilles Tjoelker
Author: jilles Date: Sat Nov 7 22:06:49 2015 New Revision: 290515 URL: https://svnweb.freebsd.org/changeset/base/290515 Log: periodic: Fix backwards compatibility for daily_status_security_* vars. Most daily_status_security_* variables in periodic.conf were changed to security_status_*

svn commit: r290453 - head

2015-11-06 Thread Jilles Tjoelker
Author: jilles Date: Fri Nov 6 16:43:22 2015 New Revision: 290453 URL: https://svnweb.freebsd.org/changeset/base/290453 Log: I still maintain sh(1). Modified: head/MAINTAINERS Modified: head/MAINTAINERS == ---

svn commit: r290244 - head/bin/sh

2015-11-01 Thread Jilles Tjoelker
Author: jilles Date: Sun Nov 1 22:07:40 2015 New Revision: 290244 URL: https://svnweb.freebsd.org/changeset/base/290244 Log: sh: Avoid copying argv for simple commands. Add dummy entries before and after so arglist's array is directly usable as argv. Modified: head/bin/sh/eval.c

svn commit: r290065 - head/lib/libedit

2015-10-27 Thread Jilles Tjoelker
Author: jilles Date: Tue Oct 27 21:16:29 2015 New Revision: 290065 URL: https://svnweb.freebsd.org/changeset/base/290065 Log: libedit: Use correct buffer lengths in vi mode v command. Libedit's vi mode provides a v command to edit the current line in vi(1) (hard-coded to vi, in fact).

Re: svn commit: r289879 - head/usr.sbin/newsyslog

2015-10-24 Thread Jilles Tjoelker
out(1) and newsyslog(8). In kill(1)'s case, the error messages are more detailed. I'm not going to add a dependency on libutil in such basic utilities though. In my humble opinion, depending on another DSO is more expensive than having a small piece of duplicated code. -- Jilles Tjoelke

svn commit: r289159 - head/bin/sh

2015-10-11 Thread Jilles Tjoelker
Author: jilles Date: Sun Oct 11 21:33:00 2015 New Revision: 289159 URL: https://svnweb.freebsd.org/changeset/base/289159 Log: sh: Make struct arglist an array instead of a linked list. This simplifies the code (e.g. allowing use of qsort(3) instead of a hand-rolled mergesort) and should

Re: svn commit: r288628 - head/sys/kern

2015-10-03 Thread Jilles Tjoelker
t; } This change makes the code match the man page, but in fact, the code was right and the man page is wrong. Per POSIX, posix_fadvise() shall return 0 on success and an error number on failure, and need not modify errno. Also, this kind of ABI change in

svn commit: r288430 - in head: bin/sh lib/libc/gen

2015-09-30 Thread Jilles Tjoelker
Author: jilles Date: Wed Sep 30 21:32:29 2015 New Revision: 288430 URL: https://svnweb.freebsd.org/changeset/base/288430 Log: wordexp: Rewrite to make WRDE_NOCMD reliable. Shell syntax is too complicated to detect command substitution and unquoted operators reliably without implementing

svn commit: r288309 - head/lib/libc/gen

2015-09-27 Thread Jilles Tjoelker
Author: jilles Date: Sun Sep 27 12:52:18 2015 New Revision: 288309 URL: https://svnweb.freebsd.org/changeset/base/288309 Log: fnmatch(): Remove exponential behaviour as in sh r229201. The old code was exponential in the number of asterisks in the pattern. However, once a match has been

Re: svn commit: r288026 - head/lib/libc/stdlib

2015-09-20 Thread Jilles Tjoelker
to applications, protected names (_foo) are not necessary. I wouldn't commit a change that only either adds or removes parameter names in prototypes myself, except to a header file visible to applications (to fix namespace pollution). -- Jilles Tjoelker ___

svn commit: r287996 - head/lib/libc/net

2015-09-19 Thread Jilles Tjoelker
Author: jilles Date: Sat Sep 19 20:27:09 2015 New Revision: 287996 URL: https://svnweb.freebsd.org/changeset/base/287996 Log: libc: Consistently call _ioctl() internally, not ioctl(). Modified: head/lib/libc/net/sockatmark.c Modified: head/lib/libc/net/sockatmark.c

svn commit: r287753 - head/lib/libc/sys

2015-09-13 Thread Jilles Tjoelker
Author: jilles Date: Sun Sep 13 14:00:49 2015 New Revision: 287753 URL: https://svnweb.freebsd.org/changeset/base/287753 Log: setuid(2): Suggest O_CLOEXEC instead of fcntl(F_SETFD). Modified: head/lib/libc/sys/setuid.2 Modified: head/lib/libc/sys/setuid.2

svn commit: r287761 - head/lib/libc/db/recno

2015-09-13 Thread Jilles Tjoelker
Author: jilles Date: Sun Sep 13 17:17:52 2015 New Revision: 287761 URL: https://svnweb.freebsd.org/changeset/base/287761 Log: db/recno: Open with close-on-exec like btree and hash do. Modified: head/lib/libc/db/recno/rec_open.c Modified: head/lib/libc/db/recno/rec_open.c

svn commit: r287408 - in head/bin/sh: . tests/parser

2015-09-02 Thread Jilles Tjoelker
Author: jilles Date: Wed Sep 2 19:49:55 2015 New Revision: 287408 URL: https://svnweb.freebsd.org/changeset/base/287408 Log: sh: Allow empty << EOF markers. Added: head/bin/sh/tests/parser/heredoc13.0 (contents, props changed) Modified: head/bin/sh/parser.c

Re: svn commit: r287217 - head/usr.sbin/syslogd

2015-08-30 Thread Jilles Tjoelker
be needed. -- Jilles Tjoelker ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to svn-src-head-unsubscr...@freebsd.org

svn commit: r287308 - in head/bin/sh: . tests/builtins

2015-08-30 Thread Jilles Tjoelker
Author: jilles Date: Sun Aug 30 17:24:22 2015 New Revision: 287308 URL: https://svnweb.freebsd.org/changeset/base/287308 Log: sh: Fix read with escaped IFS characters at the end. Characters escaped with a backslash must be treated as if they were not in IFS. This includes stripping

svn commit: r287296 - head/bin/sh

2015-08-29 Thread Jilles Tjoelker
Author: jilles Date: Sat Aug 29 19:41:47 2015 New Revision: 287296 URL: https://svnweb.freebsd.org/changeset/base/287296 Log: sh: Add set -o nolog. POSIX requires this to prevent entering function definitions in history but this implementation does nothing except retain the option's

svn commit: r287148 - in head/bin/sh: . tests/builtins

2015-08-25 Thread Jilles Tjoelker
Author: jilles Date: Tue Aug 25 21:55:15 2015 New Revision: 287148 URL: https://svnweb.freebsd.org/changeset/base/287148 Log: sh: Fix out of bounds read when there is no ] after a [:class:]. The initial check for a matching ] was incorrect if a ] may be consumed by a [:class:]. The

Re: svn commit: r286866 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src include lib/libc/gen lib/libc

2015-08-23 Thread Jilles Tjoelker
On Tue, Aug 18, 2015 at 02:28:25PM -0700, Jason Evans wrote: On Aug 18, 2015, at 2:17 PM, Jilles Tjoelker jil...@stack.nl wrote: On Tue, Aug 18, 2015 at 09:49:44PM +0200, Jan Beich wrote: Jason Evans jas...@freebsd.org writes: + - Remove the *allocm() API, which is superseded

svn commit: r287081 - in head/bin/sh: . tests/errors

2015-08-23 Thread Jilles Tjoelker
Author: jilles Date: Sun Aug 23 20:44:53 2015 New Revision: 287081 URL: https://svnweb.freebsd.org/changeset/base/287081 Log: sh: Don't create bad parse result when postponing a bad substitution error. An invalid substitution like ${var@} does not cause a parse error but is stored in the

svn commit: r286971 - head/bin/sh/tests/parser

2015-08-20 Thread Jilles Tjoelker
Author: jilles Date: Thu Aug 20 21:31:36 2015 New Revision: 286971 URL: https://svnweb.freebsd.org/changeset/base/286971 Log: sh: Add test for $'\u' without any digits. It is likely that $'\u' and $'\U' will allow fewer digits in future. However, no digits at all should still

svn commit: r286973 - in head/bin/sh: . tests/parser

2015-08-20 Thread Jilles Tjoelker
Author: jilles Date: Thu Aug 20 22:05:55 2015 New Revision: 286973 URL: https://svnweb.freebsd.org/changeset/base/286973 Log: sh: Avoid negative character values from $'\U' etc. The negative value was not expected and generated the low 8 bits as a byte, which may be an invalid

svn commit: r286941 - in head: lib/libc/gen tools/regression/lib/libc/gen

2015-08-19 Thread Jilles Tjoelker
Author: jilles Date: Wed Aug 19 20:31:03 2015 New Revision: 286941 URL: https://svnweb.freebsd.org/changeset/base/286941 Log: wordexp(): Improve some error codes. Distinguish between WRDE_BADVAL and WRDE_SYNTAX based on when the error occurred (parsing or execution), not based on whether

svn commit: r286903 - head/lib/libc/gen

2015-08-18 Thread Jilles Tjoelker
Author: jilles Date: Tue Aug 18 20:13:36 2015 New Revision: 286903 URL: https://svnweb.freebsd.org/changeset/base/286903 Log: wordexp(3): Update man page for no longer using the wordexp builtin. Modified: head/lib/libc/gen/wordexp.3 Modified: head/lib/libc/gen/wordexp.3

Re: svn commit: r286866 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src include lib/libc/gen lib/libc

2015-08-18 Thread Jilles Tjoelker
experimental APIs to build jemalloc themselves, or to use jemalloc from ports (although such a port doesn't seem to exist, currently). -- Jilles Tjoelker ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head

svn commit: r286826 - in head/bin/sh: . tests/builtins

2015-08-16 Thread Jilles Tjoelker
Author: jilles Date: Sun Aug 16 12:57:17 2015 New Revision: 286826 URL: https://svnweb.freebsd.org/changeset/base/286826 Log: sh: Backslash-newline should not affect field splitting in read builtin. This was originally broken in r212339 in 2010. Added: head/bin/sh/tests/builtins/read8.0

svn commit: r286830 - head/lib/libc/gen

2015-08-16 Thread Jilles Tjoelker
Author: jilles Date: Sun Aug 16 19:42:15 2015 New Revision: 286830 URL: https://svnweb.freebsd.org/changeset/base/286830 Log: wordexp(): Stop using the undocumented wordexp builtin. The functionality of the wordexp builtin is easily replaced using normal shell code, although performance

svn commit: r286788 - head/bin/sh

2015-08-14 Thread Jilles Tjoelker
Author: jilles Date: Fri Aug 14 21:44:15 2015 New Revision: 286788 URL: https://svnweb.freebsd.org/changeset/base/286788 Log: sh: When setting option via long name, don't go via letter. Looking up the letter makes no sense and prevents adding options that only have a long name, no

svn commit: r286649 - in head: contrib/netbsd-tests/lib/libc/locale lib/libc/tests/locale

2015-08-11 Thread Jilles Tjoelker
Author: jilles Date: Tue Aug 11 21:59:36 2015 New Revision: 286649 URL: https://svnweb.freebsd.org/changeset/base/286649 Log: Fix and re-enable UTF-8 tests. Modified: head/contrib/netbsd-tests/lib/libc/locale/t_mbrtowc.c head/contrib/netbsd-tests/lib/libc/locale/t_mbstowcs.c

Re: svn commit: r284162 - head/bin/ls

2015-08-08 Thread Jilles Tjoelker
On Sun, Jul 19, 2015 at 03:00:12PM +0200, Jilles Tjoelker wrote: On Fri, Jun 19, 2015 at 11:54:23PM +0200, Jilles Tjoelker wrote: On Mon, Jun 08, 2015 at 07:13:05PM +, Xin LI wrote: Author: delphij Date: Mon Jun 8 19:13:04 2015 New Revision: 284162 URL: https

svn commit: r286344 - head/usr.bin/find

2015-08-05 Thread Jilles Tjoelker
Author: jilles Date: Wed Aug 5 21:33:30 2015 New Revision: 286344 URL: https://svnweb.freebsd.org/changeset/base/286344 Log: find: Fix segfault with very long path in -exec/-ok ... {} \;. If the resulting argument is longer than MAXPATHLEN, realloc() was called to extend the space, but

Re: svn commit: r285985 - in head/usr.sbin/pw: . tests

2015-08-01 Thread Jilles Tjoelker
arithmetic expansion, for example largeid=$((0x1)). When using strtol() or similar functions, accepting hex typically implies accepting octal as well, which causes confusing and POSIX-violating results like 010 interpreted as eight. -- Jilles Tjoelker

Re: svn commit: r285985 - in head/usr.sbin/pw: . tests

2015-08-01 Thread Jilles Tjoelker
On Sun, Aug 02, 2015 at 02:59:00AM +1000, Bruce Evans wrote: On Sat, 1 Aug 2015, Jilles Tjoelker wrote: These values are easily written using arithmetic expansion, for example largeid=$((0x1)). Not really. Shells are also very buggy or limited in this area. I often use old

svn commit: r286163 - head/etc

2015-08-01 Thread Jilles Tjoelker
Author: jilles Date: Sat Aug 1 22:00:25 2015 New Revision: 286163 URL: https://svnweb.freebsd.org/changeset/base/286163 Log: rc.subr: Allow rc.conf.d with multi-directory local_startup. I also changed ${...%*/rc.d} to ${...%/rc.d} since the shortest match always has an empty string for

Re: svn commit: r284162 - head/bin/ls

2015-07-19 Thread Jilles Tjoelker
On Fri, Jun 19, 2015 at 11:54:23PM +0200, Jilles Tjoelker wrote: On Mon, Jun 08, 2015 at 07:13:05PM +, Xin LI wrote: Author: delphij Date: Mon Jun 8 19:13:04 2015 New Revision: 284162 URL: https://svnweb.freebsd.org/changeset/base/284162 Log: It has been long time that when

Re: svn commit: r285539 - head/sys/compat/cloudabi64

2015-07-17 Thread Jilles Tjoelker
therefore probably have a CLOUDABI_* constant. It turns out that both FreeBSD and Linux report 1024 for getconf IOV_MAX, so there is little practical effect. -- Jilles Tjoelker ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman

svn commit: r285385 - head/bin/sh

2015-07-11 Thread Jilles Tjoelker
Author: jilles Date: Sat Jul 11 13:07:26 2015 New Revision: 285385 URL: https://svnweb.freebsd.org/changeset/base/285385 Log: sh(1): libedit has supported multibyte encodings for a while. Modified: head/bin/sh/sh.1 Modified: head/bin/sh/sh.1

svn commit: r284916 - head/bin/mv

2015-06-28 Thread Jilles Tjoelker
Author: jilles Date: Sun Jun 28 21:36:00 2015 New Revision: 284916 URL: https://svnweb.freebsd.org/changeset/base/284916 Log: mv: Improve message when moving two or more files to non-directory. The message text is from cp, which has had a nicer message for this since 2007 (PR bin/50656).

svn commit: r284779 - head/bin/sh

2015-06-24 Thread Jilles Tjoelker
Author: jilles Date: Wed Jun 24 20:51:48 2015 New Revision: 284779 URL: https://svnweb.freebsd.org/changeset/base/284779 Log: sh: Fix some arithmetic undefined behaviour. Fix shifts of possibly negative numbers found with ubsan and avoid signed integer overflow when hashing an extremely

svn commit: r284649 - head/lib/libc/gen

2015-06-20 Thread Jilles Tjoelker
Author: jilles Date: Sat Jun 20 20:54:05 2015 New Revision: 284649 URL: https://svnweb.freebsd.org/changeset/base/284649 Log: fts_children: preserve errno after running close/fchdir PR: 200942 Submitted by: Conrad Meyer Differential Revision: https://reviews.freebsd.org/D2852

Re: svn commit: r284162 - head/bin/ls

2015-06-19 Thread Jilles Tjoelker
ls implementations that deviate from this annoying (e.g. on some embedded systems). -- Jilles Tjoelker ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to svn-src-head-unsubscr

Re: svn commit: r282672 - head/etc/rc.d

2015-05-11 Thread Jilles Tjoelker
in the thread. Although power_profile appears to have an appropriate REQUIRE line, it is in fact started via devd, which happens fairly early. -- Jilles Tjoelker ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head

svn commit: r282729 - head/lib/libc/net

2015-05-10 Thread Jilles Tjoelker
Author: jilles Date: Sun May 10 14:50:50 2015 New Revision: 282729 URL: https://svnweb.freebsd.org/changeset/base/282729 Log: recv(),send(): Directly call interposing entry instead of going through PLT. recv() and send()'s calls to recvfrom() and sendto() are much like waitpid()'s call

svn commit: r282482 - head/bin/cp

2015-05-05 Thread Jilles Tjoelker
Author: jilles Date: Tue May 5 13:23:03 2015 New Revision: 282482 URL: https://svnweb.freebsd.org/changeset/base/282482 Log: cp: Remove fts sorting. In an attempt to improve performance, cp reordered directories first (although the comment says directories last). This is not effective

svn commit: r282041 - head/usr.bin/hexdump

2015-04-26 Thread Jilles Tjoelker
Author: jilles Date: Sun Apr 26 21:34:55 2015 New Revision: 282041 URL: https://svnweb.freebsd.org/changeset/base/282041 Log: hexdump: Don't use uninitialized struct stat. Modified: head/usr.bin/hexdump/display.c Modified: head/usr.bin/hexdump/display.c

svn commit: r281988 - head/lib/libarchive

2015-04-25 Thread Jilles Tjoelker
Author: jilles Date: Sat Apr 25 21:25:00 2015 New Revision: 281988 URL: https://svnweb.freebsd.org/changeset/base/281988 Log: libarchive: Allow setting nanosecond timestamps. Modified: head/lib/libarchive/config_freebsd.h Modified: head/lib/libarchive/config_freebsd.h

svn commit: r281982 - head/bin/sh

2015-04-25 Thread Jilles Tjoelker
Author: jilles Date: Sat Apr 25 13:34:25 2015 New Revision: 281982 URL: https://svnweb.freebsd.org/changeset/base/281982 Log: sh: Pass along SIGINT from a child if job control is enabled, even when not interactive. I added the interactive check in r208881 to be safe, but in actual use

Re: svn commit: r281086 - head/sys/kern

2015-04-05 Thread Jilles Tjoelker
On Sun, Apr 05, 2015 at 02:23:05AM +0300, Sergey Kandaurov wrote: On 5 April 2015 at 00:47, Jilles Tjoelker jil...@freebsd.org wrote: Author: jilles Date: Sat Apr 4 21:47:54 2015 New Revision: 281086 URL: https://svnweb.freebsd.org/changeset/base/281086 Log: utimensat: Correct

svn commit: r281086 - head/sys/kern

2015-04-04 Thread Jilles Tjoelker
Author: jilles Date: Sat Apr 4 21:47:54 2015 New Revision: 281086 URL: https://svnweb.freebsd.org/changeset/base/281086 Log: utimensat: Correct Capsicum required capability rights. Modified: head/sys/kern/vfs_syscalls.c Modified: head/sys/kern/vfs_syscalls.c

svn commit: r281082 - head/lib/libc/gen

2015-04-04 Thread Jilles Tjoelker
Author: jilles Date: Sat Apr 4 20:22:12 2015 New Revision: 281082 URL: https://svnweb.freebsd.org/changeset/base/281082 Log: fts: Don't return FTS_SLNONE if it's not a symlink (if race). When following symlinks, fts returned FTS_SLNONE when fstatat(flag=0) failed, but a subsequent

svn commit: r280919 - head/lib/libc/gen

2015-03-31 Thread Jilles Tjoelker
Author: jilles Date: Tue Mar 31 20:51:01 2015 New Revision: 280919 URL: https://svnweb.freebsd.org/changeset/base/280919 Log: wordexp: Explicitly pass along IFS. Per Austin group issue #884, sh should not import IFS from the environment but always set it to $' \t\n'. For wordexp(),

svn commit: r280920 - head/bin/sh/tests/expansion

2015-03-31 Thread Jilles Tjoelker
Author: jilles Date: Tue Mar 31 20:59:37 2015 New Revision: 280920 URL: https://svnweb.freebsd.org/changeset/base/280920 Log: sh: Add more tests for exotic IFS splitting. Added: head/bin/sh/tests/expansion/ifs6.0 (contents, props changed) head/bin/sh/tests/expansion/ifs7.0 (contents,

Re: svn commit: r280308 - head/sys/fs/devfs

2015-03-29 Thread Jilles Tjoelker
) but is not so slow. The file server people won't like this though. My proposal for delayed updates as in UFS clearly does not work for TTY idle times, so there is no point in that. -- Jilles Tjoelker ___ svn-src-head@freebsd.org mailing list http

svn commit: r280830 - head/tools/regression/lib/libc/gen

2015-03-29 Thread Jilles Tjoelker
Author: jilles Date: Sun Mar 29 22:00:24 2015 New Revision: 280830 URL: https://svnweb.freebsd.org/changeset/base/280830 Log: wordexp(): Add testcase for non-default IFS in environment. The non-default IFS is expected to be used. MFC after:1 week Modified:

<    1   2   3   4   5   6   7   8   9   10   >