> when I attempted to increase the max number of hotlinks in ODB , defined as
> #define MAX_OPEN_RECORDS 256 /**< number of open DB records */
> assert(sizeof(DATABASE_CLIENT) == 2112);
Yes, it is intended to work like this. If you change MAX_OPEN_RECORDS (and some settings),
you break binary compatibility with standard MIDAS and the asserts inform you about it.
It is not a light step to take - you have to recompile all MIDAS clients, and if you miss
one and run it against your non-standard MIDAS, kaboom everything will go,
there is no safety net against this.
In the ALPHA experiment at CERN, for years we have been running with MAX_OPEN_RECORDS set to 2560,
and it works, you have to change both MAX_OPEN_RECORDS in midas.h and the expected values
in the assert() statements.
The new correct values you do not need to guess or compute yourself, the code to print
them is right there and it is easy to enable.
Replacing the numeric constants with computed values of course would completely defeat
the purpose of the tests - to catch the situation where by mistake or by ignorance
(or by miscompilation) sizes of critical data structures become different from those
normally expected.
K.O. |