From 09e4b5658c3d40bb820f93f7a019004a04d299a5 Mon Sep 17 00:00:00 2001 From: "warren%netscape.com" Date: Fri, 10 Sep 1999 23:34:12 +0000 Subject: [PATCH] Disabled the page manager until we have more time to make it work properly. --- xpcom/io/nsPipe2.cpp | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/xpcom/io/nsPipe2.cpp b/xpcom/io/nsPipe2.cpp index 8bcfacb764c4..f84e75060ddf 100644 --- a/xpcom/io/nsPipe2.cpp +++ b/xpcom/io/nsPipe2.cpp @@ -772,13 +772,20 @@ NS_NewPipe(nsIBufferInputStream* *inStrResult, PRUint32 maxSize) { nsresult rv; -#ifdef XP_MAC + const nsCID* cid = &kAllocatorCID; +#if 0 + // Take the page manager out altogether because some unices don't + // know how to reserve VM -- only preallocate it which takes up a lot + // of space. +#ifndef XP_MAC // Don't use page buffers on the mac because we don't really have // VM there, and they end up being more wasteful: - NS_WITH_SERVICE(nsIAllocator, alloc, kAllocatorCID, &rv); -#else - NS_WITH_SERVICE(nsIAllocator, alloc, kPageManagerCID, &rv); + if (segmentSize >= NS_PAGEMGR_PAGE_SIZE) { + cid = &kPageManagerCID; + } #endif +#endif + NS_WITH_SERVICE(nsIAllocator, alloc, *cid, &rv); if (NS_FAILED(rv)) return rv; nsPipe* pipe = new nsPipe();