protected DLink BaseGetNodeFromReserve() { // If pReserve is empty, refill with growDelta if (pReserve == null) { AddToReservedList(this.growDelta); } // Get and remove head of pReserve (as pNode) Debug.Assert(pReserve != null); DLink pNodeToActivate = pReserve; // Set new head of Reserve pReserve = pReserve.GetNext(); // If new head is not null, clear its previous link to newly activated node if (pReserve != null) { pReserve.SetPrev(null); } // "Clean" values of pNode pNodeToActivate.Clean(); return(pNodeToActivate); }