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

[xml] initGenericErrorDefaultFunc weirdness.




	Odd, I am trying to use:

	initGenericErrorDefaultFunc((xmlGenericErrorFunc)MyXMLErrorFunction);

	But I get this error on compilation:

main.c:109: passing arg 1 of `initGenericErrorDefaultFunc' from incompatible pointer type

	And here's my function:

void MyXMLErrorFunction(void *ctx, const char *msg, ...)
{
	printf("Aiee!  And error has occured!\n");
}


I've tried everything: using the direct address, different assignments and so on, but I either get the same error or bus errors. I *do* have this working:

	xmlSetGenericErrorFunc(NULL, (xmlGenericErrorFunc)MyXMLErrorFunction);

	And that works fine.

But, am I doing something wrong with the declaration/assignment of 'initGenericErrorDefaultFunc' or is it b0rked?


Regards,
		Jose.




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