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: r294532 - stable/10/lib/libc/sys

2016-01-21 Thread Jilles Tjoelker
Author: jilles Date: Thu Jan 21 21:16:57 2016 New Revision: 294532 URL: https://svnweb.freebsd.org/changeset/base/294532 Log: MFC r294234: utimensat(2): Correct description of [EINVAL] error. Modified: stable/10/lib/libc/sys/utimensat.2 Directory Properties: stable/10/ (props changed)

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

svn commit: r294099 - stable/10/lib/libc/sys

2016-01-15 Thread Jilles Tjoelker
Author: jilles Date: Fri Jan 15 20:55:44 2016 New Revision: 294099 URL: https://svnweb.freebsd.org/changeset/base/294099 Log: MFC r293783: futimens/utimensat: Use the new system calls. Update the __FreeBSD_version check in lib/libc/sys/futimens.c and lib/libc/sys/utimensat.c. Before

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

Re: svn commit: r277610 - in head: bin/ln lib/libc/include lib/libc/sys share/man/man4 sys/compat/freebsd32 sys/kern sys/sys usr.bin/kdump

2016-01-07 Thread Jilles Tjoelker
On Thu, Jan 07, 2016 at 04:03:25PM +0300, Chagin Dmitry wrote: > On Fri, Jan 23, 2015 at 09:07:09PM +0000, Jilles Tjoelker wrote: > > Author: jilles > > Date: Fri Jan 23 21:07:08 2015 > > New Revision: 277610 > > URL: https://svnweb.freebsd.org/changeset/base/277610

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: r293120 - head/bin/sh/tests/builtins

2016-01-03 Thread Jilles Tjoelker
Author: jilles Date: Sun Jan 3 22:16:27 2016 New Revision: 293120 URL: https://svnweb.freebsd.org/changeset/base/293120 Log: sh: Link tests/builtins/getopts9.0 to the build. This was forgotten in r273700. Modified: head/bin/sh/tests/builtins/Makefile Modified:

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: r292841 - stable/10/etc/defaults

2015-12-28 Thread Jilles Tjoelker
Author: jilles Date: Mon Dec 28 21:35:06 2015 New Revision: 292841 URL: https://svnweb.freebsd.org/changeset/base/292841 Log: MFC r290515: periodic: Fix backwards compatibility for daily_status_security_* vars. Most daily_status_security_* variables in periodic.conf were changed to

svn commit: r292786 - stable/10/bin/sh

2015-12-27 Thread Jilles Tjoelker
Author: jilles Date: Sun Dec 27 17:53:39 2015 New Revision: 292786 URL: https://svnweb.freebsd.org/changeset/base/292786 Log: MFC r292517: sh/mknodes: Close files and check for errors when writing. This is a build tool only and does not affect run time. PR: 204951 Modified:

svn commit: r292776 - stable/10/lib/libc/sys

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

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

svn commit: r292664 - stable/10/bin/sh

2015-12-23 Thread Jilles Tjoelker
Author: jilles Date: Wed Dec 23 18:24:40 2015 New Revision: 292664 URL: https://svnweb.freebsd.org/changeset/base/292664 Log: MFC r292360: sh: Fix use-after-free when attempting to modify a read-only variable. Reported by: bapt Modified: stable/10/bin/sh/var.c Directory Properties:

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 fi

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: r292511 - stable/10/lib/libc/gen

2015-12-20 Thread Jilles Tjoelker
Author: jilles Date: Sun Dec 20 13:41:06 2015 New Revision: 292511 URL: https://svnweb.freebsd.org/changeset/base/292511 Log: MFC r292130: exec(3): Fix COMPATIBILITY section: default path does not contain cwd. Modified: stable/10/lib/libc/gen/exec.3 Directory Properties: stable/10/

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: r292450 - stable/10/etc

2015-12-18 Thread Jilles Tjoelker
Author: jilles Date: Fri Dec 18 19:58:34 2015 New Revision: 292450 URL: https://svnweb.freebsd.org/changeset/base/292450 Log: MFC r291770: 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

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: r290062 - stable/10/etc

2015-10-27 Thread Jilles Tjoelker
Author: jilles Date: Tue Oct 27 20:58:14 2015 New Revision: 290062 URL: https://svnweb.freebsd.org/changeset/base/290062 Log: MFC r286163: 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

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).

svn commit: r289943 - stable/10/lib/libc/gen

2015-10-25 Thread Jilles Tjoelker
Author: jilles Date: Sun Oct 25 21:39:23 2015 New Revision: 289943 URL: https://svnweb.freebsd.org/changeset/base/289943 Log: MFC r288309: fnmatch(): Remove exponential behaviour as in sh r229201. The old code was exponential in the number of asterisks in the pattern. However, once a

svn commit: r289938 - in stable/10: bin/sh lib/libc/gen

2015-10-25 Thread Jilles Tjoelker
Author: jilles Date: Sun Oct 25 17:17:50 2015 New Revision: 289938 URL: https://svnweb.freebsd.org/changeset/base/289938 Log: MFC r288430: wordexp: Rewrite to make WRDE_NOCMD reliable. Shell syntax is too complicated to detect command substitution and unquoted operators reliably without

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 Tjoelker _

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: r287751 - stable/10/bin/sh

2015-09-13 Thread Jilles Tjoelker
Author: jilles Date: Sun Sep 13 13:52:54 2015 New Revision: 287751 URL: https://svnweb.freebsd.org/changeset/base/287751 Log: MFC r278826,279330: sh: Various cleanups to expand.c: * Remove some gotos. * Remove unused parameter. * Remove duplicate code. This MFC is to avoid

svn commit: r287755 - in stable/10/bin/sh/tests: expansion parameters parser

2015-09-13 Thread Jilles Tjoelker
Author: jilles Date: Sun Sep 13 14:24:12 2015 New Revision: 287755 URL: https://svnweb.freebsd.org/changeset/base/287755 Log: MFC r268436,273243,278806,280920,286971: sh: Add various tests. These new tests from head pass with unmodified stable/10 sh. Added:

svn commit: r287752 - in stable/10/bin/sh: . tests/builtins

2015-09-13 Thread Jilles Tjoelker
Author: jilles Date: Sun Sep 13 13:58:46 2015 New Revision: 287752 URL: https://svnweb.freebsd.org/changeset/base/287752 Log: MFC r287148: 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

svn commit: r287750 - stable/10/bin/sh

2015-09-13 Thread Jilles Tjoelker
Author: jilles Date: Sun Sep 13 13:43:08 2015 New Revision: 287750 URL: https://svnweb.freebsd.org/changeset/base/287750 Log: MFC r272575: sh: Eliminate some gotos. This MFC is to avoid conflicts in the MFC of r287148. Modified: stable/10/bin/sh/eval.c stable/10/bin/sh/expand.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: r287749 - in stable/10/bin/sh: . tests/errors

2015-09-13 Thread Jilles Tjoelker
Author: jilles Date: Sun Sep 13 13:31:51 2015 New Revision: 287749 URL: https://svnweb.freebsd.org/changeset/base/287749 Log: MFC r287081: 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

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-all@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-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: r287298 - stable/10/lib/libc/gen

2015-08-29 Thread Jilles Tjoelker
Author: jilles Date: Sat Aug 29 20:41:09 2015 New Revision: 287298 URL: https://svnweb.freebsd.org/changeset/base/287298 Log: MFC r279084,280713: setmode(): Use sysctl kern.proc.umask instead of umask() if possible. The kern.proc.umask.pid sysctl allows querying the umask without

svn commit: r287266 - stable/10/usr.bin/find

2015-08-28 Thread Jilles Tjoelker
Author: jilles Date: Fri Aug 28 20:53:08 2015 New Revision: 287266 URL: https://svnweb.freebsd.org/changeset/base/287266 Log: MFC r286344: find: Fix segfault with very long path in -exec/-ok ... {} \;. If the resulting argument is longer than MAXPATHLEN, realloc() was called to extend

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: r287027 - stable/10/bin/mv

2015-08-22 Thread Jilles Tjoelker
Author: jilles Date: Sat Aug 22 21:35:35 2015 New Revision: 287027 URL: https://svnweb.freebsd.org/changeset/base/287027 Log: MFC r284916: 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

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-all@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-all

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: r286813 - stable/10/bin/sh

2015-08-15 Thread Jilles Tjoelker
Author: jilles Date: Sat Aug 15 19:58:00 2015 New Revision: 286813 URL: https://svnweb.freebsd.org/changeset/base/286813 Log: MFC r284779: sh: Fix some arithmetic undefined behaviour. Fix shifts of possibly negative numbers found with ubsan and avoid signed integer overflow when hashing

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

svn commit: r286534 - stable/10/lib/libc/gen

2015-08-09 Thread Jilles Tjoelker
Author: jilles Date: Sun Aug 9 15:53:02 2015 New Revision: 286534 URL: https://svnweb.freebsd.org/changeset/base/286534 Log: MFC r284649: fts_children: preserve errno after running close/fchdir PR: 200942 Submitted by: Conrad Meyer Modified: stable/10/lib/libc/gen/fts.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

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: 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

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-all@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-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr

svn commit: r284001 - head/lib/libc/string

2015-06-04 Thread Jilles Tjoelker
Author: jilles Date: Thu Jun 4 21:54:46 2015 New Revision: 284001 URL: https://svnweb.freebsd.org/changeset/base/284001 Log: strchr(3): Mdoc fixes. Modified: head/lib/libc/string/strchr.3 Modified: head/lib/libc/string/strchr.3

Re: svn commit: r282917 - stable/9/bin/cp

2015-05-17 Thread Jilles Tjoelker
On Fri, May 15, 2015 at 06:28:10AM +, Alexey Dokuchaev wrote: On Thu, May 14, 2015 at 07:32:13PM +, Jilles Tjoelker wrote: Author: jilles Date: Thu May 14 19:32:13 2015 New Revision: 282917 URL: https://svnweb.freebsd.org/changeset/base/282917 Log: MFC r282482: cp: Remove

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