Carbon


SetPtrSize

Header: MacMemory.h Carbon status: Supported

Changes the logical size of the nonrelocatable block corresponding to a pointer.

void SetPtrSize (
    Ptr p, 
    Size newSize
);
p

A pointer to a nonrelocatable block.

newSize

The desired new logical size, in bytes, of the nonrelocatable block.

DISCUSSION

An attempt to increase the size of a nonrelocatable block might fail because of a block above it that is either nonrelocatable or locked. You should be prepared for this possibility.

Call the function MemError to get the result code. See “Result Codes”.

Because SetPtrSize allocates memory, you should not call it at interrupt time.

AVAILABILITY

Supported in Carbon. Available in CarbonLib 1.0 and later when InterfaceLib 7.1 or later is installed. Exported by CarbonLib 1.0 and later and by InterfaceLib 7.1 and later.


© 2000 Apple Computer, Inc. — (Last Updated 4/6/2000)