[Date Prev][Date Next][Thread Prev][Thread Next][Thread Index]

Re: [XaraXtreme-dev] Startup problems due to help

--On 11 July 2006 12:13 +0200 Martin Wuerthner <lists@xxxxxxxxxxxxxxx> wrote:

I guess, that happened because InitHelp returned FALSE without setting
the error somewhere. If any initialisation fails, InitKernel calls
InformError() without any argument, assuming that the static error
message has been set by the component that failed to initialise. It
might be a good idea to set this to some generic error message at the
beginning to cover that case - everything would be better than having
an empty error box. As development continues it is well possible that
this can happen again because it is difficult to enforce an interface
like "you may only return FALSE from an initialisation routine if you
have set the static error".

It's a pretty standard Camelot rule that if a function is documented
as returning false for an error, you HAVE to have set the error. Not
doing so is very naughty! (that's what the ERRORxxx macros do).