8 APTR
PM_AllocVecPooled(LONG size
)
10 #if defined(__AROS__) || defined(__MORPHOS__)
13 // To Do: Add Semaphore protection to the pool!!!
14 // stegerg: MOS and AROS have MEMF_SEM_PROTECTED. See pminit.c
16 size
+= sizeof(ULONG
);
18 p
= AllocPooled(MemPool
, size
);
25 return AllocVec(size
, MEMF_CLEAR
);
29 void PM_FreeVecPooled(APTR mem
)
31 #if defined(__AROS__) || defined(__MORPHOS__)
32 ULONG
*p
= (ULONG
*)mem
;
34 FreePooled(MemPool
, p
, *p
);
40 ULONG
PM_String_Length(STRPTR s
)
49 STRPTR
PM_String_Copy(STRPTR Source
, STRPTR Dest
, LONG Len
)
52 while(*Source
) *Dest
++=*Source
++;
59 Dest
[ctr
]=Source
[ctr
];
66 ULONG
PM_String_Compare(STRPTR str1
, STRPTR str2
)
69 if(!str1
|| !str2
) return 0;
73 if(!str1
[i
] || !str2
[i
] || j
) return j
;
77 void PM_StrCat(STRPTR str1
, STRPTR str2
)
80 while(*str2
) *str1
++=*str2
++;