diff --git a/src/plg.cpp b/src/plg.cpp index c5c3782..358a67a 100644 --- a/src/plg.cpp +++ b/src/plg.cpp @@ -185,8 +185,8 @@ PluginList::registerPlugin(int32 size, uint32 id, p->rightsCallback = nil; p->alwaysCallback = nil; p->parentList = this; - this->plugins.add(&p->inParentList); - allPlugins.add(&p->inGlobalList); + this->plugins.append(&p->inParentList); + allPlugins.append(&p->inGlobalList); return p->offset; } diff --git a/src/rwbase.h b/src/rwbase.h index 6179dd6..6bc8a54 100644 --- a/src/rwbase.h +++ b/src/rwbase.h @@ -70,9 +70,13 @@ typedef int32 bool32; typedef uint8 byte; typedef uint32 uint; +#ifndef nil #define nil NULL +#endif +#ifndef nelem #define nelem(A) (sizeof(A) / sizeof A[0]) +#endif #ifdef __GNUC__ #define RWALIGN(n) __attribute__ ((aligned (n)))