Search
lxdream.org :: lxdream :: r1270:65fd19c07e2e
lxdream 0.9.1
released Jun 29
Download Now
changeset1270:65fd19c07e2e
parent1269:50c63f63bf8f
child1271:3edc4bdd7c0b
authornkeynes
dateThu Mar 15 08:21:22 2012 +1000 (9 years ago)
Add assert to make sure we're not registering too many modules. Possibly
should just make this a linked list anyway.
src/dreamcast.c
1.1 --- a/src/dreamcast.c Mon Mar 12 18:06:24 2012 +1000
1.2 +++ b/src/dreamcast.c Thu Mar 15 08:21:22 2012 +1000
1.3 @@ -213,6 +213,7 @@
1.4
1.5 void dreamcast_register_module( dreamcast_module_t module )
1.6 {
1.7 + assert( num_modules < MAX_MODULES );
1.8 modules[num_modules++] = module;
1.9 if( module->init != NULL )
1.10 module->init();
.