Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(21)

Unified Diff: nss/mozilla/nsprpub/pr/src/misc/prsystem.c

Issue 3135002: Update to NSS 3.12.7 and NSPR 4.8.6.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/deps/third_party/
Patch Set: Created 10 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: nss/mozilla/nsprpub/pr/src/misc/prsystem.c
===================================================================
--- nss/mozilla/nsprpub/pr/src/misc/prsystem.c (revision 55475)
+++ nss/mozilla/nsprpub/pr/src/misc/prsystem.c (working copy)
@@ -284,6 +284,20 @@
long pageCount = sysconf(_SC_PHYS_PAGES);
bytes = (PRUint64) pageSize * pageCount;
+#elif defined(NETBSD)
+
+ int mib[2];
+ int rc;
+ uint64_t memSize;
+ size_t len = sizeof(memSize);
+
+ mib[0] = CTL_HW;
+ mib[1] = HW_PHYSMEM64;
+ rc = sysctl(mib, 2, &memSize, &len, NULL, 0);
+ if (-1 != rc) {
+ bytes = memSize;
+ }
+
#elif defined(HPUX)
struct pst_static info;

Powered by Google App Engine
This is Rietveld 408576698