From owner-svn-src-stable-9@FreeBSD.ORG Thu Nov 14 21:27:14 2013 Return-Path: Delivered-To: svn-src-stable-9@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 ESMTPS id F1EEAD7; Thu, 14 Nov 2013 21:27:13 +0000 (UTC) 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 E09C32F5E; Thu, 14 Nov 2013 21:27:13 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id rAELRDOX095684; Thu, 14 Nov 2013 21:27:13 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id rAELRDhp095683; Thu, 14 Nov 2013 21:27:13 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201311142127.rAELRDhp095683@svn.freebsd.org> From: John Baldwin Date: Thu, 14 Nov 2013 21:27:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r258144 - stable/9/sys/vm X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Nov 2013 21:27:14 -0000 Author: jhb Date: Thu Nov 14 21:27:13 2013 New Revision: 258144 URL: http://svnweb.freebsd.org/changeset/base/258144 Log: MFC 255497: Fix an off-by-one error when populating mincore(2) entries for skipped entries. lastvecindex references the last valid byte, so the new bytes should come after it. Modified: stable/9/sys/vm/vm_mmap.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/vm/vm_mmap.c ============================================================================== --- stable/9/sys/vm/vm_mmap.c Thu Nov 14 20:21:05 2013 (r258143) +++ stable/9/sys/vm/vm_mmap.c Thu Nov 14 21:27:13 2013 (r258144) @@ -963,12 +963,12 @@ RestartScan: * the byte vector is zeroed for those skipped entries. */ while ((lastvecindex + 1) < vecindex) { + ++lastvecindex; error = subyte(vec + lastvecindex, 0); if (error) { error = EFAULT; goto done2; } - ++lastvecindex; } /* @@ -1004,12 +1004,12 @@ RestartScan: */ vecindex = OFF_TO_IDX(end - first_addr); while ((lastvecindex + 1) < vecindex) { + ++lastvecindex; error = subyte(vec + lastvecindex, 0); if (error) { error = EFAULT; goto done2; } - ++lastvecindex; } /*