Code:
initMySQL
initAsyncMySQL
what this?

Are you sure that the cvars are not null? (Yes, i know: libcod checks params, but look what you get there at the moment of call the function)