From owner-svn-ports-head@FreeBSD.ORG Wed Jul 10 17:57:08 2013 Return-Path: Delivered-To: svn-ports-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 61859933; Wed, 10 Jul 2013 17:57:08 +0000 (UTC) (envelope-from decke@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 535221111; Wed, 10 Jul 2013 17:57:08 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r6AHv8G3027907; Wed, 10 Jul 2013 17:57:08 GMT (envelope-from decke@svn.freebsd.org) Received: (from decke@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r6AHv8Tn027904; Wed, 10 Jul 2013 17:57:08 GMT (envelope-from decke@svn.freebsd.org) Message-Id: <201307101757.r6AHv8Tn027904@svn.freebsd.org> From: Bernhard Froehlich Date: Wed, 10 Jul 2013 17:57:08 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r322726 - in head/emulators/virtualbox-ose: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Jul 2013 17:57:08 -0000 Author: decke Date: Wed Jul 10 17:57:07 2013 New Revision: 322726 URL: http://svnweb.freebsd.org/changeset/ports/322726 Log: - Fix querying total and available RAM on i386 Submitted by: Cy Schubert Modified: head/emulators/virtualbox-ose/Makefile head/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r3-freebsd-RTSystemQueryTotalRam-freebsd.cpp Modified: head/emulators/virtualbox-ose/Makefile ============================================================================== --- head/emulators/virtualbox-ose/Makefile Wed Jul 10 17:57:00 2013 (r322725) +++ head/emulators/virtualbox-ose/Makefile Wed Jul 10 17:57:07 2013 (r322726) @@ -3,6 +3,7 @@ PORTNAME= virtualbox-ose DISTVERSION= 4.2.16 +PORTREVISION= 1 CATEGORIES= emulators MASTER_SITES= http://download.virtualbox.org/virtualbox/${DISTVERSION}/ \ http://tmp.chruetertee.ch/ \ Modified: head/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r3-freebsd-RTSystemQueryTotalRam-freebsd.cpp ============================================================================== --- head/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r3-freebsd-RTSystemQueryTotalRam-freebsd.cpp Wed Jul 10 17:57:00 2013 (r322725) +++ head/emulators/virtualbox-ose/files/patch-src-VBox-Runtime-r3-freebsd-RTSystemQueryTotalRam-freebsd.cpp Wed Jul 10 17:57:07 2013 (r322726) @@ -55,7 +55,7 @@ + includes non-main memory as well */ + *pcb = 0; + if (sysctl(mib, 2, pcb, &pcblen, NULL, 0) == 0) { -+ if (pcblen == sizeof(*pcb)) ++ if (pcblen == sizeof(*pcb) || pcblen == sizeof(uint32_t)) + return VINF_SUCCESS; + else + return VERR_NO_MEMORY; /* XXX */ @@ -74,7 +74,7 @@ + mib[1] = HW_USERMEM; + *pcb = 0; + if (sysctl(mib, 2, pcb, &pcblen, NULL, 0) == 0) { -+ if (pcblen == sizeof(*pcb)) ++ if (pcblen == sizeof(*pcb) || pcblen == sizeof(uint32_t)) + return VINF_SUCCESS; + else + return VERR_NO_MEMORY; /* XXX */