2 Copyright © 1995-2001, The AROS Development Team. All rights reserved.
9 #include <proto/exec.h>
11 #include <exec/types.h>
12 #include "dos_intern.h"
14 extern void Exec_FreeMem();
16 /*****************************************************************************
19 #include <proto/dos.h>
21 AROS_LH1(BOOL
, UnLoadSeg
,
24 AROS_LHA(BPTR
, seglist
, D1
),
27 struct DosLibrary
*, DOSBase
, 26, Dos
)
30 Free a segment list allocated with LoadSeg().
33 seglist - The segment list.
36 success = returns whether everything went ok. Returns FALSE if
49 *****************************************************************************/
52 AROS_LIBBASE_EXT_DECL(struct DosLibrary
*,DOSBase
)
56 #if AROS_MODULES_DEBUG
57 extern struct MinList debug_seglist
;
58 extern struct MinList free_debug_segnodes
;
59 struct debug_segnode
*segnode
;
62 ForeachNode(&debug_seglist
, segnode
)
64 if (segnode
->seglist
== seglist
)
67 ADDHEAD(&free_debug_segnodes
, segnode
);
73 return InternalUnLoadSeg(seglist
, __AROS_GETVECADDR(SysBase
, 35));