From owner-svn-src-head@FreeBSD.ORG Tue Oct 29 17:34:16 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 7D2D6DF8; Tue, 29 Oct 2013 17:34:16 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 6AE0E2799; Tue, 29 Oct 2013 17:34:16 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9THYGq6061873; Tue, 29 Oct 2013 17:34:16 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9THYGoF061872; Tue, 29 Oct 2013 17:34:16 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201310291734.r9THYGoF061872@svn.freebsd.org> From: Xin LI Date: Tue, 29 Oct 2013 17:34:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r257348 - head/sbin/newfs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 29 Oct 2013 17:34:16 -0000 Author: delphij Date: Tue Oct 29 17:34:15 2013 New Revision: 257348 URL: http://svnweb.freebsd.org/changeset/base/257348 Log: Don't call arc4random_stir() explicitly. To quote arc4random(3) manual page: There is no need to call arc4random_stir() before using arc4random() functions family, since they automatically initialize themselves. No objection: des MFC after: 2 weeks Modified: head/sbin/newfs/mkfs.c Modified: head/sbin/newfs/mkfs.c ============================================================================== --- head/sbin/newfs/mkfs.c Tue Oct 29 17:31:16 2013 (r257347) +++ head/sbin/newfs/mkfs.c Tue Oct 29 17:34:15 2013 (r257348) @@ -134,12 +134,10 @@ mkfs(struct partition *pp, char *fsys) */ disk.d_bsize = sectorsize; disk.d_ufs = Oflag; - if (Rflag) { + if (Rflag) utime = 1000000000; - } else { + else time(&utime); - arc4random_stir(); - } sblock.fs_old_flags = FS_FLAGS_UPDATED; sblock.fs_flags = 0; if (Uflag)