From owner-svn-src-stable-10@freebsd.org Sun Dec 10 13:45:43 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 37B93E8D24A; Sun, 10 Dec 2017 13:45:43 +0000 (UTC) (envelope-from eugen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 023F271E22; Sun, 10 Dec 2017 13:45:42 +0000 (UTC) (envelope-from eugen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBADjfDt048144; Sun, 10 Dec 2017 13:45:41 GMT (envelope-from eugen@FreeBSD.org) Received: (from eugen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBADjf0x048142; Sun, 10 Dec 2017 13:45:41 GMT (envelope-from eugen@FreeBSD.org) Message-Id: <201712101345.vBADjf0x048142@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: eugen set sender to eugen@FreeBSD.org using -f From: Eugene Grosbein Date: Sun, 10 Dec 2017 13:45:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r326745 - stable/10/sys/geom/raid X-SVN-Group: stable-10 X-SVN-Commit-Author: eugen X-SVN-Commit-Paths: stable/10/sys/geom/raid X-SVN-Commit-Revision: 326745 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 10 Dec 2017 13:45:43 -0000 Author: eugen Date: Sun Dec 10 13:45:41 2017 New Revision: 326745 URL: https://svnweb.freebsd.org/changeset/base/326745 Log: MFC r326655,326668: correct error handling for graid SINGLE/CONCAT/RAID5 volumes. Approved by: mav (mentor) Modified: stable/10/sys/geom/raid/tr_concat.c stable/10/sys/geom/raid/tr_raid5.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/geom/raid/tr_concat.c ============================================================================== --- stable/10/sys/geom/raid/tr_concat.c Sun Dec 10 13:44:58 2017 (r326744) +++ stable/10/sys/geom/raid/tr_concat.c Sun Dec 10 13:45:41 2017 (r326745) @@ -339,7 +339,7 @@ g_raid_tr_iodone_concat(struct g_raid_tr_object *tr, pbp->bio_inbed++; if (pbp->bio_children == pbp->bio_inbed) { pbp->bio_completed = pbp->bio_length; - g_raid_iodone(pbp, bp->bio_error); + g_raid_iodone(pbp, pbp->bio_error); } } Modified: stable/10/sys/geom/raid/tr_raid5.c ============================================================================== --- stable/10/sys/geom/raid/tr_raid5.c Sun Dec 10 13:44:58 2017 (r326744) +++ stable/10/sys/geom/raid/tr_raid5.c Sun Dec 10 13:45:41 2017 (r326745) @@ -371,15 +371,15 @@ g_raid_tr_iodone_raid5(struct g_raid_tr_object *tr, struct g_raid_subdisk *sd, struct bio *bp) { struct bio *pbp; - int error; pbp = bp->bio_parent; + if (pbp->bio_error == 0) + pbp->bio_error = bp->bio_error; pbp->bio_inbed++; - error = bp->bio_error; g_destroy_bio(bp); if (pbp->bio_children == pbp->bio_inbed) { pbp->bio_completed = pbp->bio_length; - g_raid_iodone(pbp, error); + g_raid_iodone(pbp, pbp->bio_error); } } From owner-svn-src-stable-10@freebsd.org Sun Dec 10 13:58:38 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 85E11E8D531; Sun, 10 Dec 2017 13:58:38 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 51BF17238A; Sun, 10 Dec 2017 13:58:38 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBADwbNK052461; Sun, 10 Dec 2017 13:58:37 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBADwbm2052460; Sun, 10 Dec 2017 13:58:37 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201712101358.vBADwbm2052460@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Sun, 10 Dec 2017 13:58:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r326746 - in stable: 10/lib/msun/man 11/lib/msun/man X-SVN-Group: stable-10 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable: 10/lib/msun/man 11/lib/msun/man X-SVN-Commit-Revision: 326746 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 10 Dec 2017 13:58:38 -0000 Author: dim Date: Sun Dec 10 13:58:37 2017 New Revision: 326746 URL: https://svnweb.freebsd.org/changeset/base/326746 Log: MFC r326669: Remove the sentence in math(3) about some long double math functions not being available. Submitted by: Steve Kargl Modified: stable/10/lib/msun/man/math.3 Directory Properties: stable/10/ (props changed) Changes in other areas also in this revision: Modified: stable/11/lib/msun/man/math.3 Directory Properties: stable/11/ (props changed) Modified: stable/10/lib/msun/man/math.3 ============================================================================== --- stable/10/lib/msun/man/math.3 Sun Dec 10 13:45:41 2017 (r326745) +++ stable/10/lib/msun/man/math.3 Sun Dec 10 13:58:37 2017 (r326746) @@ -28,7 +28,7 @@ .\" from: @(#)math.3 6.10 (Berkeley) 5/6/91 .\" $FreeBSD$ .\" -.Dd December 5, 2010 +.Dd December 7, 2017 .Dt MATH 3 .Os .Sh NAME @@ -235,12 +235,6 @@ and .Vt long double values, were written for or imported into subsequent versions of FreeBSD. .Sh BUGS -Some of the -.Vt "long double" -math functions in -.St -isoC-99 -are not available. -.Pp Many of the routines to compute transcendental functions produce inaccurate results in other than the default rounding mode. .Pp From owner-svn-src-stable-10@freebsd.org Sun Dec 10 14:49:08 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 348A1E8E489; Sun, 10 Dec 2017 14:49:08 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id F1D1773918; Sun, 10 Dec 2017 14:49:07 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBAEn6Bq073457; Sun, 10 Dec 2017 14:49:06 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBAEn6TI073456; Sun, 10 Dec 2017 14:49:06 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201712101449.vBAEn6TI073456@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Sun, 10 Dec 2017 14:49:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r326747 - in stable: 10/lib/msun/bsdsrc 11/lib/msun/bsdsrc X-SVN-Group: stable-10 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable: 10/lib/msun/bsdsrc 11/lib/msun/bsdsrc X-SVN-Commit-Revision: 326747 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 10 Dec 2017 14:49:08 -0000 Author: dim Date: Sun Dec 10 14:49:06 2017 New Revision: 326747 URL: https://svnweb.freebsd.org/changeset/base/326747 Log: MFC r326670: Remove an unused incude from lib/msun/bsdsrc/b_log.c. Submitted by: Steve Kargl Modified: stable/10/lib/msun/bsdsrc/b_log.c Directory Properties: stable/10/ (props changed) Changes in other areas also in this revision: Modified: stable/11/lib/msun/bsdsrc/b_log.c Directory Properties: stable/11/ (props changed) Modified: stable/10/lib/msun/bsdsrc/b_log.c ============================================================================== --- stable/10/lib/msun/bsdsrc/b_log.c Sun Dec 10 13:58:37 2017 (r326746) +++ stable/10/lib/msun/bsdsrc/b_log.c Sun Dec 10 14:49:06 2017 (r326747) @@ -36,7 +36,6 @@ __FBSDID("$FreeBSD$"); #include -#include #include "mathimpl.h" From owner-svn-src-stable-10@freebsd.org Mon Dec 11 05:10:12 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E64E6E86494; Mon, 11 Dec 2017 05:10:12 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A24AF71AD3; Mon, 11 Dec 2017 05:10:12 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBB5ABKP034548; Mon, 11 Dec 2017 05:10:11 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBB5ABTH034547; Mon, 11 Dec 2017 05:10:11 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201712110510.vBB5ABTH034547@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Mon, 11 Dec 2017 05:10:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r326761 - stable/10/usr.sbin/inetd X-SVN-Group: stable-10 X-SVN-Commit-Author: delphij X-SVN-Commit-Paths: stable/10/usr.sbin/inetd X-SVN-Commit-Revision: 326761 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Dec 2017 05:10:13 -0000 Author: delphij Date: Mon Dec 11 05:10:11 2017 New Revision: 326761 URL: https://svnweb.freebsd.org/changeset/base/326761 Log: MFC r326244: Don't assign rs as we will assign it later. Modified: stable/10/usr.sbin/inetd/builtins.c Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.sbin/inetd/builtins.c ============================================================================== --- stable/10/usr.sbin/inetd/builtins.c Mon Dec 11 05:06:28 2017 (r326760) +++ stable/10/usr.sbin/inetd/builtins.c Mon Dec 11 05:10:11 2017 (r326761) @@ -167,10 +167,8 @@ chargen_stream(int s, struct servtab *sep) inetd_setproctitle(sep->se_service, s); - if (!endring) { + if (!endring) initring(); - rs = ring; - } text[LINESIZ] = '\r'; text[LINESIZ + 1] = '\n'; From owner-svn-src-stable-10@freebsd.org Mon Dec 11 05:21:49 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EAF9DE869B9; Mon, 11 Dec 2017 05:21:49 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9EF01723CA; Mon, 11 Dec 2017 05:21:49 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBB5Lm9C041979; Mon, 11 Dec 2017 05:21:48 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBB5LmE8041978; Mon, 11 Dec 2017 05:21:48 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201712110521.vBB5LmE8041978@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Mon, 11 Dec 2017 05:21:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r326763 - stable/10/usr.bin/find X-SVN-Group: stable-10 X-SVN-Commit-Author: delphij X-SVN-Commit-Paths: stable/10/usr.bin/find X-SVN-Commit-Revision: 326763 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Dec 2017 05:21:50 -0000 Author: delphij Date: Mon Dec 11 05:21:48 2017 New Revision: 326763 URL: https://svnweb.freebsd.org/changeset/base/326763 Log: MFC r325723: find(1): Don't treat statfs() error as fatal in f_fstype, which can happen when a directory is removed in the middle of find. Instead of a full err(), allow find to continue, plus print a warning with exitstatus set when appropriate. Reported by: 100.chksetuid via gordon Reviewed by: jilles Modified: stable/10/usr.bin/find/function.c Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.bin/find/function.c ============================================================================== --- stable/10/usr.bin/find/function.c Mon Dec 11 05:19:45 2017 (r326762) +++ stable/10/usr.bin/find/function.c Mon Dec 11 05:21:48 2017 (r326763) @@ -896,8 +896,13 @@ f_fstype(PLAN *plan, FTSENT *entry) } else p = NULL; - if (statfs(entry->fts_accpath, &sb)) - err(1, "%s", entry->fts_accpath); + if (statfs(entry->fts_accpath, &sb)) { + if (!ignore_readdir_race || errno != ENOENT) { + warn("statfs: %s", entry->fts_accpath); + exitstatus = 1; + } + return 0; + } if (p) { p[0] = save[0]; From owner-svn-src-stable-10@freebsd.org Tue Dec 12 04:08:31 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6A1DAE8B60F; Tue, 12 Dec 2017 04:08:31 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 35F8B6A73F; Tue, 12 Dec 2017 04:08:31 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBC48UcC031355; Tue, 12 Dec 2017 04:08:30 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBC48UiW031354; Tue, 12 Dec 2017 04:08:30 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201712120408.vBC48UiW031354@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Tue, 12 Dec 2017 04:08:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r326790 - stable/10/usr.bin/find X-SVN-Group: stable-10 X-SVN-Commit-Author: delphij X-SVN-Commit-Paths: stable/10/usr.bin/find X-SVN-Commit-Revision: 326790 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Dec 2017 04:08:31 -0000 Author: delphij Date: Tue Dec 12 04:08:30 2017 New Revision: 326790 URL: https://svnweb.freebsd.org/changeset/base/326790 Log: Revert r326763. The change depends on r264387 which was not merged. Pointy hat to: delphij Modified: stable/10/usr.bin/find/function.c Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.bin/find/function.c ============================================================================== --- stable/10/usr.bin/find/function.c Tue Dec 12 03:16:10 2017 (r326789) +++ stable/10/usr.bin/find/function.c Tue Dec 12 04:08:30 2017 (r326790) @@ -896,13 +896,8 @@ f_fstype(PLAN *plan, FTSENT *entry) } else p = NULL; - if (statfs(entry->fts_accpath, &sb)) { - if (!ignore_readdir_race || errno != ENOENT) { - warn("statfs: %s", entry->fts_accpath); - exitstatus = 1; - } - return 0; - } + if (statfs(entry->fts_accpath, &sb)) + err(1, "%s", entry->fts_accpath); if (p) { p[0] = save[0]; From owner-svn-src-stable-10@freebsd.org Tue Dec 12 22:10:14 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8568FE86BD9; Tue, 12 Dec 2017 22:10:14 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4F21E75814; Tue, 12 Dec 2017 22:10:14 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBCMADMB094532; Tue, 12 Dec 2017 22:10:13 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBCMADK8094529; Tue, 12 Dec 2017 22:10:13 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201712122210.vBCMADK8094529@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Tue, 12 Dec 2017 22:10:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r326814 - in stable/10/sys: amd64/linux amd64/linux32 i386/linux X-SVN-Group: stable-10 X-SVN-Commit-Author: pfg X-SVN-Commit-Paths: in stable/10/sys: amd64/linux amd64/linux32 i386/linux X-SVN-Commit-Revision: 326814 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Dec 2017 22:10:14 -0000 Author: pfg Date: Tue Dec 12 22:10:12 2017 New Revision: 326814 URL: https://svnweb.freebsd.org/changeset/base/326814 Log: MFC r326282: (by fsu) Remap ENOATTR to ENODATA in the linuxulator. In the linux ENOADATA is frequently #defined as ENOATTR. The change is required for an xattrs support implementation. Modified: stable/10/sys/amd64/linux/linux_sysvec.c stable/10/sys/amd64/linux32/linux32_sysvec.c stable/10/sys/i386/linux/linux_sysvec.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/amd64/linux/linux_sysvec.c ============================================================================== --- stable/10/sys/amd64/linux/linux_sysvec.c Tue Dec 12 22:08:34 2017 (r326813) +++ stable/10/sys/amd64/linux/linux_sysvec.c Tue Dec 12 22:10:12 2017 (r326814) @@ -147,7 +147,7 @@ static int bsd_to_linux_errno[ELAST + 1] = { -100,-101,-102,-103,-104,-105,-106,-107,-108,-109, -110,-111, -40, -36,-112,-113, -39, -11, -87,-122, -116, -66, -6, -6, -6, -6, -6, -37, -38, -9, - -6, -6, -43, -42, -75,-125, -84, -95, -16, -74, + -6, -6, -43, -42, -75,-125, -84, -61, -16, -74, -72, -67, -71 }; Modified: stable/10/sys/amd64/linux32/linux32_sysvec.c ============================================================================== --- stable/10/sys/amd64/linux32/linux32_sysvec.c Tue Dec 12 22:08:34 2017 (r326813) +++ stable/10/sys/amd64/linux32/linux32_sysvec.c Tue Dec 12 22:10:12 2017 (r326814) @@ -146,7 +146,7 @@ static int bsd_to_linux_errno[ELAST + 1] = { -100,-101,-102,-103,-104,-105,-106,-107,-108,-109, -110,-111, -40, -36,-112,-113, -39, -11, -87,-122, -116, -66, -6, -6, -6, -6, -6, -37, -38, -9, - -6, -6, -43, -42, -75,-125, -84, -95, -16, -74, + -6, -6, -43, -42, -75,-125, -84, -61, -16, -74, -72, -67, -71 }; Modified: stable/10/sys/i386/linux/linux_sysvec.c ============================================================================== --- stable/10/sys/i386/linux/linux_sysvec.c Tue Dec 12 22:08:34 2017 (r326813) +++ stable/10/sys/i386/linux/linux_sysvec.c Tue Dec 12 22:10:12 2017 (r326814) @@ -145,7 +145,7 @@ static int bsd_to_linux_errno[ELAST + 1] = { -100,-101,-102,-103,-104,-105,-106,-107,-108,-109, -110,-111, -40, -36,-112,-113, -39, -11, -87,-122, -116, -66, -6, -6, -6, -6, -6, -37, -38, -9, - -6, -6, -43, -42, -75,-125, -84, -95, -16, -74, + -6, -6, -43, -42, -75,-125, -84, -61, -16, -74, -72, -67, -71 }; From owner-svn-src-stable-10@freebsd.org Wed Dec 13 06:20:20 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F337FE92A6A; Wed, 13 Dec 2017 06:20:19 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BF29A63C42; Wed, 13 Dec 2017 06:20:19 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBD6KI6m097464; Wed, 13 Dec 2017 06:20:18 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBD6KIrY097463; Wed, 13 Dec 2017 06:20:18 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201712130620.vBD6KIrY097463@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Wed, 13 Dec 2017 06:20:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r326818 - stable/10/usr.bin/ipcs X-SVN-Group: stable-10 X-SVN-Commit-Author: delphij X-SVN-Commit-Paths: stable/10/usr.bin/ipcs X-SVN-Commit-Revision: 326818 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Dec 2017 06:20:20 -0000 Author: delphij Date: Wed Dec 13 06:20:18 2017 New Revision: 326818 URL: https://svnweb.freebsd.org/changeset/base/326818 Log: MFC r326361: Remove unused include. Modified: stable/10/usr.bin/ipcs/ipc.c Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.bin/ipcs/ipc.c ============================================================================== --- stable/10/usr.bin/ipcs/ipc.c Wed Dec 13 06:17:20 2017 (r326817) +++ stable/10/usr.bin/ipcs/ipc.c Wed Dec 13 06:20:18 2017 (r326818) @@ -44,7 +44,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include #include "ipc.h" From owner-svn-src-stable-10@freebsd.org Wed Dec 13 18:38:04 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 01779E82BF9; Wed, 13 Dec 2017 18:38:04 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C87527CF98; Wed, 13 Dec 2017 18:38:03 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBDIc2Xk007625; Wed, 13 Dec 2017 18:38:02 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBDIc2OM007623; Wed, 13 Dec 2017 18:38:02 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201712131838.vBDIc2OM007623@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Wed, 13 Dec 2017 18:38:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r326830 - in stable: 10/lib/msun/man 11/lib/msun/man X-SVN-Group: stable-10 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable: 10/lib/msun/man 11/lib/msun/man X-SVN-Commit-Revision: 326830 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Dec 2017 18:38:04 -0000 Author: dim Date: Wed Dec 13 18:38:02 2017 New Revision: 326830 URL: https://svnweb.freebsd.org/changeset/base/326830 Log: MFC r326748: Document the existence and precision of the remaining long double functions for which an imprecise stub implementation was added in r255294, namely powl(3) and tgammal(3). Submitted by: Steve Kargl MFC r326753: Correct r326748, indicating that tgammal(3) is mapped to tgamma(3), not to itself. Noticed by: jilles Modified: stable/10/lib/msun/man/exp.3 stable/10/lib/msun/man/lgamma.3 Directory Properties: stable/10/ (props changed) Changes in other areas also in this revision: Modified: stable/11/lib/msun/man/exp.3 stable/11/lib/msun/man/lgamma.3 Directory Properties: stable/11/ (props changed) Modified: stable/10/lib/msun/man/exp.3 ============================================================================== --- stable/10/lib/msun/man/exp.3 Wed Dec 13 17:11:57 2017 (r326829) +++ stable/10/lib/msun/man/exp.3 Wed Dec 13 18:38:02 2017 (r326830) @@ -28,7 +28,7 @@ .\" from: @(#)exp.3 6.12 (Berkeley) 7/31/91 .\" $FreeBSD$ .\" -.Dd November 9, 2015 +.Dd December 8, 2017 .Dt EXP 3 .Os .Sh NAME @@ -180,6 +180,15 @@ If 0**0 = 1, then then \*(Na**0 = 1 too because x**0 = 1 for all finite and infinite x, i.e., independently of x. .El +.Sh BUGS +To conform with newer C/C++ standards, a stub implementation for +.Nm powl +was committed to the math library, where +.Nm powl +is mapped to +.Nm pow . +Thus, the numerical accuracy is at most that of the 53-bit double +precision implementation. .Sh SEE ALSO .Xr fenv 3 , .Xr ldexp 3 , Modified: stable/10/lib/msun/man/lgamma.3 ============================================================================== --- stable/10/lib/msun/man/lgamma.3 Wed Dec 13 17:11:57 2017 (r326829) +++ stable/10/lib/msun/man/lgamma.3 Wed Dec 13 18:38:02 2017 (r326830) @@ -28,7 +28,7 @@ .\" from: @(#)lgamma.3 6.6 (Berkeley) 12/3/92 .\" $FreeBSD$ .\" -.Dd September 12, 2014 +.Dd December 8, 2017 .Dt LGAMMA 3 .Os .Sh NAME @@ -43,7 +43,8 @@ .Nm gammaf , .Nm gammaf_r , .Nm tgamma , -.Nm tgammaf +.Nm tgammaf , +.Nm tgammal , .Nd log gamma functions, gamma function .Sh LIBRARY .Lb libm @@ -76,6 +77,8 @@ .Fn tgamma "double x" .Ft float .Fn tgammaf "float x" +.Ft "long double" +.Fn tgammal "long double x" .Sh DESCRIPTION .Fn lgamma x , .Fn lgammaf x , @@ -106,9 +109,10 @@ and but the caller must provide an integer to store the sign of \(*G(x). .Pp The -.Fn tgamma x +.Fn tgamma x , +.Fn tgammaf x , and -.Fn tgammaf x +.Fn tgammal x functions return \(*G(x), with no effect on .Fa signgam . .Pp @@ -167,6 +171,15 @@ non-positive integers. For large non-integer negative values, .Fn tgamma will underflow. +.Sh BUGS +To conform with newer C/C++ standards, a stub implementation for +.Nm tgammal +was committed to the math library, where +.Nm tgammal +is mapped to +.Nm tgamma . +Thus, the numerical accuracy is at most that of the 53-bit double +precision implementation. .Sh SEE ALSO .Xr math 3 .Sh STANDARDS @@ -175,8 +188,9 @@ The .Fn lgammaf , .Fn lgammal , .Fn tgamma , +.Fn tgammaf , and -.Fn tgammaf +.Fn tgammal functions are expected to conform to .St -isoC-99 . .Sh HISTORY From owner-svn-src-stable-10@freebsd.org Wed Dec 13 20:15:25 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7196EE85348; Wed, 13 Dec 2017 20:15:25 +0000 (UTC) (envelope-from cy@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3A97780FD1; Wed, 13 Dec 2017 20:15:25 +0000 (UTC) (envelope-from cy@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBDKFOxT049736; Wed, 13 Dec 2017 20:15:24 GMT (envelope-from cy@FreeBSD.org) Received: (from cy@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBDKFOVe049734; Wed, 13 Dec 2017 20:15:24 GMT (envelope-from cy@FreeBSD.org) Message-Id: <201712132015.vBDKFOVe049734@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cy set sender to cy@FreeBSD.org using -f From: Cy Schubert Date: Wed, 13 Dec 2017 20:15:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r326833 - in stable: 10 11 X-SVN-Group: stable-10 X-SVN-Commit-Author: cy X-SVN-Commit-Paths: in stable: 10 11 X-SVN-Commit-Revision: 326833 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Dec 2017 20:15:25 -0000 Author: cy Date: Wed Dec 13 20:15:23 2017 New Revision: 326833 URL: https://svnweb.freebsd.org/changeset/base/326833 Log: MFC r324248: hen building multiple kernels using KERNCONF, non-existent KERNCONF files will produce an error and buildkernel will fail. Previously missing KERNCONF files silently failed giving no indication as to why, only to subsequently discover during installkernel that the desired kernel was never built in the first place. This is a rework of r302865. This is the correct patch. Reviewed by: ngie (previous version, r302865) Differential Revision: https://reviews.freebsd.org/D7167 Modified: stable/10/Makefile.inc1 stable/10/UPDATING Directory Properties: stable/10/ (props changed) Changes in other areas also in this revision: Modified: stable/11/Makefile.inc1 stable/11/UPDATING Directory Properties: stable/11/ (props changed) Modified: stable/10/Makefile.inc1 ============================================================================== --- stable/10/Makefile.inc1 Wed Dec 13 19:36:29 2017 (r326832) +++ stable/10/Makefile.inc1 Wed Dec 13 20:15:23 2017 (r326833) @@ -1030,6 +1030,10 @@ BUILDKERNELS+= ${_kernel} .if empty(INSTALLKERNEL) && !defined(NO_INSTALLKERNEL) INSTALLKERNEL= ${_kernel} .endif +.else +.if make(buildkernel) +.error Missing KERNCONF ${KERNCONFDIR}/${_kernel} +.endif .endif .endfor Modified: stable/10/UPDATING ============================================================================== --- stable/10/UPDATING Wed Dec 13 19:36:29 2017 (r326832) +++ stable/10/UPDATING Wed Dec 13 20:15:23 2017 (r326833) @@ -16,6 +16,13 @@ from older versions of FreeBSD, try WITHOUT_CLANG to b stable/10, and then rebuild without this option. The bootstrap process from older version of current is a bit fragile. +20171003: + When building multiple kernels using KERNCONF, non-existent KERNCONF + files will produce an error and buildkernel will fail. Previously + missing KERNCONF files silently failed giving no indication as to + why, only to subsequently discover during installkernel that the + desired kernel was never built in the first place. + 20170824: Since the switch to GPT disk labels, fsck for UFS/FFS has been unable to automatically find alternate superblocks. As of r322860, From owner-svn-src-stable-10@freebsd.org Thu Dec 14 07:55:12 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 72D69E9ACF5; Thu, 14 Dec 2017 07:55:12 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3F36E794E1; Thu, 14 Dec 2017 07:55:12 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBE7tB9F044770; Thu, 14 Dec 2017 07:55:11 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBE7tB63044769; Thu, 14 Dec 2017 07:55:11 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201712140755.vBE7tB63044769@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Thu, 14 Dec 2017 07:55:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r326843 - stable/10/sbin/fsck_msdosfs X-SVN-Group: stable-10 X-SVN-Commit-Author: delphij X-SVN-Commit-Paths: stable/10/sbin/fsck_msdosfs X-SVN-Commit-Revision: 326843 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Dec 2017 07:55:12 -0000 Author: delphij Date: Thu Dec 14 07:55:11 2017 New Revision: 326843 URL: https://svnweb.freebsd.org/changeset/base/326843 Log: MFC r326391: Prevent OOB access on corrupted msdos directories. Submitted by: Veo Zhang Modified: stable/10/sbin/fsck_msdosfs/dir.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sbin/fsck_msdosfs/dir.c ============================================================================== --- stable/10/sbin/fsck_msdosfs/dir.c Thu Dec 14 07:52:38 2017 (r326842) +++ stable/10/sbin/fsck_msdosfs/dir.c Thu Dec 14 07:55:11 2017 (r326843) @@ -619,7 +619,7 @@ readDosDirSection(int f, struct bootblock *boot, struc dirent.name[8] = '\0'; for (k = 7; k >= 0 && dirent.name[k] == ' '; k--) dirent.name[k] = '\0'; - if (dirent.name[k] != '\0') + if (k < 0 || dirent.name[k] != '\0') k++; if (dirent.name[0] == SLOT_E5) dirent.name[0] = 0xe5; From owner-svn-src-stable-10@freebsd.org Thu Dec 14 11:45:03 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 90B2DEA0D36; Thu, 14 Dec 2017 11:45:03 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5C9D680226; Thu, 14 Dec 2017 11:45:03 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBEBj2wA040570; Thu, 14 Dec 2017 11:45:02 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBEBj27T040569; Thu, 14 Dec 2017 11:45:02 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201712141145.vBEBj27T040569@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Thu, 14 Dec 2017 11:45:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r326846 - stable/10/sys/ufs/ufs X-SVN-Group: stable-10 X-SVN-Commit-Author: kib X-SVN-Commit-Paths: stable/10/sys/ufs/ufs X-SVN-Commit-Revision: 326846 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Dec 2017 11:45:03 -0000 Author: kib Date: Thu Dec 14 11:45:02 2017 New Revision: 326846 URL: https://svnweb.freebsd.org/changeset/base/326846 Log: MFC r326657: Fix livelock in ufsdirhash_create(). Modified: stable/10/sys/ufs/ufs/ufs_dirhash.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/ufs/ufs/ufs_dirhash.c ============================================================================== --- stable/10/sys/ufs/ufs/ufs_dirhash.c Thu Dec 14 11:41:12 2017 (r326845) +++ stable/10/sys/ufs/ufs/ufs_dirhash.c Thu Dec 14 11:45:02 2017 (r326846) @@ -189,9 +189,11 @@ ufsdirhash_create(struct inode *ip) struct dirhash *ndh; struct dirhash *dh; struct vnode *vp; + bool excl; ndh = dh = NULL; vp = ip->i_vnode; + excl = false; for (;;) { /* Racy check for i_dirhash to prefetch a dirhash structure. */ if (ip->i_dirhash == NULL && ndh == NULL) { @@ -228,8 +230,11 @@ ufsdirhash_create(struct inode *ip) ufsdirhash_hold(dh); VI_UNLOCK(vp); - /* Acquire a shared lock on existing hashes. */ - sx_slock(&dh->dh_lock); + /* Acquire a lock on existing hashes. */ + if (excl) + sx_xlock(&dh->dh_lock); + else + sx_slock(&dh->dh_lock); /* The hash could've been recycled while we were waiting. */ VI_LOCK(vp); @@ -250,9 +255,10 @@ ufsdirhash_create(struct inode *ip) * so we can recreate it. If we fail the upgrade, drop our * lock and try again. */ - if (sx_try_upgrade(&dh->dh_lock)) + if (excl || sx_try_upgrade(&dh->dh_lock)) break; sx_sunlock(&dh->dh_lock); + excl = true; } /* Free the preallocated structure if it was not necessary. */ if (ndh) { From owner-svn-src-stable-10@freebsd.org Thu Dec 14 13:10:24 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 10FF9EA38DB; Thu, 14 Dec 2017 13:10:24 +0000 (UTC) (envelope-from eugen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DF0C437AA; Thu, 14 Dec 2017 13:10:23 +0000 (UTC) (envelope-from eugen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBEDANc2073720; Thu, 14 Dec 2017 13:10:23 GMT (envelope-from eugen@FreeBSD.org) Received: (from eugen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBEDAMKd073714; Thu, 14 Dec 2017 13:10:22 GMT (envelope-from eugen@FreeBSD.org) Message-Id: <201712141310.vBEDAMKd073714@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: eugen set sender to eugen@FreeBSD.org using -f From: Eugene Grosbein Date: Thu, 14 Dec 2017 13:10:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r326849 - stable/10/usr.sbin/pw X-SVN-Group: stable-10 X-SVN-Commit-Author: eugen X-SVN-Commit-Paths: stable/10/usr.sbin/pw X-SVN-Commit-Revision: 326849 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Dec 2017 13:10:24 -0000 Author: eugen Date: Thu Dec 14 13:10:22 2017 New Revision: 326849 URL: https://svnweb.freebsd.org/changeset/base/326849 Log: MFC r326738: pw(8): correct expiration period handling and command line overrides to preconfigured values for -e, -p and -w flags. Use non-negative symbols instead of magic values in passwd_val/pw_password functions. PR: 223431 Submitted by: Yuri Pankov (in part, patch for the manual) Approved by: mav (mentor) Relnotes: yes Modified: stable/10/usr.sbin/pw/psdate.c stable/10/usr.sbin/pw/psdate.h stable/10/usr.sbin/pw/pw.8 stable/10/usr.sbin/pw/pw.h stable/10/usr.sbin/pw/pw_conf.c stable/10/usr.sbin/pw/pw_user.c Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.sbin/pw/psdate.c ============================================================================== --- stable/10/usr.sbin/pw/psdate.c Thu Dec 14 13:06:41 2017 (r326848) +++ stable/10/usr.sbin/pw/psdate.c Thu Dec 14 13:10:22 2017 (r326849) @@ -38,7 +38,7 @@ static const char rcsid[] = #include "psdate.h" -static int +int numerics(char const * str) { Modified: stable/10/usr.sbin/pw/psdate.h ============================================================================== --- stable/10/usr.sbin/pw/psdate.h Thu Dec 14 13:06:41 2017 (r326848) +++ stable/10/usr.sbin/pw/psdate.h Thu Dec 14 13:10:22 2017 (r326849) @@ -33,6 +33,7 @@ #include __BEGIN_DECLS +int numerics(char const * str); time_t parse_date(time_t dt, char const * str); void print_date(char *buf, time_t t, int dotime); __END_DECLS Modified: stable/10/usr.sbin/pw/pw.8 ============================================================================== --- stable/10/usr.sbin/pw/pw.8 Thu Dec 14 13:06:41 2017 (r326848) +++ stable/10/usr.sbin/pw/pw.8 Thu Dec 14 13:10:22 2017 (r326849) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd April 23, 2016 +.Dd December 10, 2017 .Dt PW 8 .Os .Sh NAME @@ -611,6 +611,14 @@ that the account expires. A value of 0 suppresses automatic calculation of the expiry date. .It Fl p Ar days Set the default password expiration period in days. +When +.Fl D +is used, the +.Ar days +argument is interpreted differently. +It must be numeric and represents the number of days after creation +that the account expires. +A value of 0 suppresses automatic calculation of the expiry date. .It Fl g Ar group Set the default group for new users. If a blank group is specified using Modified: stable/10/usr.sbin/pw/pw.h ============================================================================== --- stable/10/usr.sbin/pw/pw.h Thu Dec 14 13:06:41 2017 (r326848) +++ stable/10/usr.sbin/pw/pw.h Thu Dec 14 13:10:22 2017 (r326849) @@ -47,6 +47,14 @@ enum _mode M_NUM }; +enum _passmode +{ + P_NO, + P_NONE, + P_RANDOM, + P_YES +}; + enum _which { W_USER, Modified: stable/10/usr.sbin/pw/pw_conf.c ============================================================================== --- stable/10/usr.sbin/pw/pw_conf.c Thu Dec 14 13:06:41 2017 (r326848) +++ stable/10/usr.sbin/pw/pw_conf.c Thu Dec 14 13:10:22 2017 (r326849) @@ -198,18 +198,18 @@ passwd_val(char const * str, int dflt) for (i = 0; booltrue[i]; i++) if (strcmp(str, booltrue[i]) == 0) - return 1; + return P_YES; for (i = 0; boolfalse[i]; i++) if (strcmp(str, boolfalse[i]) == 0) - return 0; + return P_NO; /* * Special cases for defaultpassword */ if (strcmp(str, "random") == 0) - return -1; + return P_RANDOM; if (strcmp(str, "none") == 0) - return -2; + return P_NONE; errx(1, "Invalid value for default password"); } Modified: stable/10/usr.sbin/pw/pw_user.c ============================================================================== --- stable/10/usr.sbin/pw/pw_user.c Thu Dec 14 13:06:41 2017 (r326848) +++ stable/10/usr.sbin/pw/pw_user.c Thu Dec 14 13:10:22 2017 (r326849) @@ -517,7 +517,9 @@ pw_password(struct userconf * cnf, char const * user, char pwbuf[32]; switch (cnf->default_password) { - case -1: /* Random password */ + case P_NONE: /* No password at all! */ + return ""; + case P_RANDOM: /* Random password */ l = (arc4random() % 8 + 8); /* 8 - 16 chars */ for (i = 0; i < l; i++) pwbuf[i] = chars[arc4random_uniform(sizeof(chars)-1)]; @@ -533,17 +535,13 @@ pw_password(struct userconf * cnf, char const * user, fflush(stdout); } break; - - case -2: /* No password at all! */ - return ""; - - case 0: /* No login - default */ - default: - return "*"; - - case 1: /* user's name */ + case P_YES: /* user's name */ strlcpy(pwbuf, user, sizeof(pwbuf)); break; + case P_NO: /* No login - default */ + /* FALLTHROUGH */ + default: + return "*"; } return pw_pwcrypt(pwbuf); } @@ -1124,11 +1122,20 @@ validate_mode(char *mode) return (m); } +static long +validate_expire(char *str, int opt) +{ + if (!numerics(str)) + errx(EX_DATAERR, "-%c argument must be numeric " + "when setting defaults: %s", (char)opt, str); + return strtol(str, NULL, 0); +} + static void mix_config(struct userconf *cmdcnf, struct userconf *cfg) { - if (cmdcnf->default_password == 0) + if (cmdcnf->default_password < 0) cmdcnf->default_password = cfg->default_password; if (cmdcnf->reuse_uids == 0) cmdcnf->reuse_uids = cfg->reuse_uids; @@ -1166,9 +1173,9 @@ mix_config(struct userconf *cmdcnf, struct userconf *c cmdcnf->min_gid = cfg->min_gid; if (cmdcnf->max_gid == 0) cmdcnf->max_gid = cfg->max_gid; - if (cmdcnf->expire_days == 0) + if (cmdcnf->expire_days < 0) cmdcnf->expire_days = cfg->expire_days; - if (cmdcnf->password_days == 0) + if (cmdcnf->password_days < 0) cmdcnf->password_days = cfg->password_days; } @@ -1200,6 +1207,9 @@ pw_user_add(int argc, char **argv, char *arg1) if ((cmdcnf = calloc(1, sizeof(struct userconf))) == NULL) err(EXIT_FAILURE, "calloc()"); + cmdcnf->default_password = cmdcnf->expire_days = cmdcnf->password_days = -1; + now = time(NULL); + if (arg1 != NULL) { if (arg1[strspn(arg1, "0123456789")] == '\0') id = pw_checkid(arg1, UID_MAX); @@ -1228,12 +1238,16 @@ pw_user_add(int argc, char **argv, char *arg1) homedir = optarg; break; case 'e': - now = time(NULL); - cmdcnf->expire_days = parse_date(now, optarg); + if (genconf) + cmdcnf->expire_days = validate_expire(optarg, ch); + else + cmdcnf->expire_days = parse_date(now, optarg); break; case 'p': - now = time(NULL); - cmdcnf->password_days = parse_date(now, optarg); + if (genconf) + cmdcnf->password_days = validate_expire(optarg, ch); + else + cmdcnf->password_days = parse_date(now, optarg); break; case 'g': validate_grname(cmdcnf, optarg); @@ -1371,8 +1385,12 @@ pw_user_add(int argc, char **argv, char *arg1) pwd->pw_uid = pw_uidpolicy(cmdcnf, id); pwd->pw_gid = pw_gidpolicy(cnf, grname, pwd->pw_name, (gid_t) pwd->pw_uid, dryrun); - pwd->pw_change = cmdcnf->password_days; - pwd->pw_expire = cmdcnf->expire_days; + + if (cmdcnf->password_days > 0) + pwd->pw_change = now + cmdcnf->password_days * 86400L; + if (cmdcnf->expire_days > 0) + pwd->pw_expire = now + cmdcnf->expire_days * 86400L; + pwd->pw_dir = pw_homepolicy(cmdcnf, homedir, pwd->pw_name); pwd->pw_shell = pw_shellpolicy(cmdcnf); lc = login_getpwclass(pwd); @@ -1513,6 +1531,7 @@ pw_user_mod(int argc, char **argv, char *arg1) class = nispasswd = NULL; quiet = createhome = pretty = dryrun = nis = precrypted = false; edited = false; + now = time(NULL); if (arg1 != NULL) { if (arg1[strspn(arg1, "0123456789")] == '\0') @@ -1542,11 +1561,9 @@ pw_user_mod(int argc, char **argv, char *arg1) homedir = optarg; break; case 'e': - now = time(NULL); expire_days = parse_date(now, optarg); break; case 'p': - now = time(NULL); password_days = parse_date(now, optarg); break; case 'g': @@ -1681,13 +1698,14 @@ pw_user_mod(int argc, char **argv, char *arg1) } } - if (password_days >= 0 && pwd->pw_change != password_days) { - pwd->pw_change = password_days; + + if (password_days >= 0) { + pwd->pw_change = now + password_days * 86400L; edited = true; } - if (expire_days >= 0 && pwd->pw_expire != expire_days) { - pwd->pw_expire = expire_days; + if (expire_days >= 0) { + pwd->pw_expire = now + expire_days * 86400L; edited = true; }