Important: The information in this document is obsolete and should not be used for new development.
HandAndHand
Use theHandAndHand
function to concatenate two relocatable blocks.
FUNCTION HandAndHand (aHndl, bHndl: Handle): OSErr;
aHndl
- A handle to the first relocatable block, whose contents do not change but are concatenated to the end of the second relocatable block.
bHndl
- A handle to the second relocatable block, whose size the Memory Manager expands so that it can concatenate the information from
aHndl
to the end of the contents of this block.DESCRIPTION
TheHandAndHand
function concatenates the information from the relocatable block to whichaHndl
is a handle onto the end of the relocatable block to whichbHndl
is a handle. TheaHndl
variable remains unchanged.
- WARNING
- The
HandAndHand
function dereferences the handleaHndl
. You must call theHLock
procedure to lock the block before callingHandAndHand
. Afterward, you can call theHUnlock
procedure to unlock it. Alternatively, you can save the block's original state by calling theHGetState
function, lock the block by callingHLock
, and then restore the original settings by callingHSetState
.SPECIAL CONSIDERATIONS
BecauseHandAndHand
moves memory, you should not call it at interrupt time.ASSEMBLY-LANGUAGE INFORMATION
The registers on entry and exit forHandAndHand
are
Registers on entry A0 Handle to be concatenated A1 Handle to contain itself, data from A0's handle
Registers on exit A0 Handle to concatenated data D0 Result code RESULT CODES
noErr 0 No error memFullErr -108 Not enough memory nilHandleErr -109 NIL
master pointermemWZErr -111 Attempt to operate on a free block