2 Copyright © <year>, The AROS Development Team. All rights reserved.
8 #include <proto/exec.h>
10 #include LC_LIBDEFS_FILE
12 /*****************************************************************************
15 #include <proto/setpatch.h>
17 AROS_LH1(BOOL
, AddPatch
,
20 AROS_LHA(struct PatchEntry
*, pe
, A0
),
23 struct SetPatchBase
*, SetPatchBase
, 5, Setpatch
)
29 pe - Patch entry header
33 TRUE - Patch entry is added to the master patch list
34 FALSE - Patch with matching name already in the list
48 *****************************************************************************/
53 struct PatchEntry
*tmp
;
55 ObtainSemaphore(&SetPatchBase
->sp_Patch3
.sp_Semaphore
);
57 ForeachNode(&SetPatchBase
->sp_Patch3
.sp_PatchList
, tmp
) {
58 if (strcmp(pe
->pe_Name
, tmp
->pe_Name
) == 0) {
65 AddTail((struct List
*)&SetPatchBase
->sp_Patch3
.sp_PatchList
, (struct Node
*)pe
);
67 ReleaseSemaphore(&SetPatchBase
->sp_Patch3
.sp_Semaphore
);