Skip to Content
Amiga Assembly Library v41.21 — Motorola 68020 shared library for Commodore Amiga
DocumentationExecFreeListName

FreeListName

Synopsis

FreeListName(list) A0

C Prototype

void FreeListName(struct List *list);

Description

FreeListName() is entirely similar to FreeList(), with one difference: if the LN_NAME field in each Node structure is not NULL, that address is freed assuming it was previously allocated via exec/AllocVec(). If the LN_NAME field is NULL, FreeListName() behaves identically to FreeList() for that node.

Inputs

  • list — Address of an initialized List structure to free.

Result

None.

See Also

FreeList, FreeNode, FreeNodeName

Implementation

The original 68020 assembly implementation:

; (26-Feb-1995) --- FreeListName(list) (a0) _LVOFreeListName movem.l a4-a6,-(sp) move.l a0,a4 ; A4 = struct List * move.l ab_ExecBase(a6),a6 ; Get Exec right away... FLNCont move.l (a4),a1 move.l (a1),d0 beq.s FLNLst ; Go free the List structure move.l a1,a5 ; Save for FreeMem() move.l a4,a0 ; struct List * REMOVE ; exec MACROS move.l LN_NAME(a5),d0 beq.s ONode move.l d0,a1 move.l -(a1),d0 jsr _LVOFreeMem(a6) ; Free the string... ONode lea -4(a5),a1 moveq #4+LN_SIZE,d0 jsr _LVOFreeMem(a6) bra.s FLNCont FLNLst lea -4(a4),a1 moveq #4+LH_SIZE,d0 jsr _LVOFreeMem(a6) movem.l (sp)+,a4-a6 rts
Last updated on