1999-04-15 20:05:38 +02:00
|
|
|
#include "zsh.mdh"
|
|
|
|
|
2006-05-31 00:35:03 +02:00
|
|
|
int setup_ _((Module));
|
1999-04-15 20:05:38 +02:00
|
|
|
int boot_ _((Module));
|
|
|
|
int cleanup_ _((Module));
|
2006-05-31 00:35:03 +02:00
|
|
|
int finish_ _((Module));
|
1999-04-15 20:05:38 +02:00
|
|
|
int modentry _((int boot, Module m));
|
|
|
|
|
|
|
|
/**/
|
|
|
|
int
|
|
|
|
modentry(int boot, Module m)
|
|
|
|
{
|
2006-05-31 00:35:03 +02:00
|
|
|
switch (boot) {
|
|
|
|
case 0:
|
|
|
|
return setup_(m);
|
|
|
|
break;
|
|
|
|
|
|
|
|
case 1:
|
1999-04-15 20:05:38 +02:00
|
|
|
return boot_(m);
|
2006-05-31 00:35:03 +02:00
|
|
|
break;
|
|
|
|
|
|
|
|
case 2:
|
1999-04-15 20:05:38 +02:00
|
|
|
return cleanup_(m);
|
2006-05-31 00:35:03 +02:00
|
|
|
break;
|
|
|
|
|
|
|
|
case 3:
|
|
|
|
return finish_(m);
|
|
|
|
break;
|
|
|
|
|
|
|
|
default:
|
|
|
|
zerr("bad call to modentry");
|
|
|
|
return 1;
|
|
|
|
break;
|
|
|
|
}
|
1999-04-15 20:05:38 +02:00
|
|
|
}
|