Re: [xml] Linking against the Libxml2 using a non standard XML(Patch)



Johnson, Cameron wrote:

Due to factors beyond my control I must compile our application with
_stdcall.  Although a lot of work has been done so that the functions
can be used with any calling convention, I had to make the following
changes to get the application to link and run.

File: xmlmemory.h
Line 57
        From:
        typedef void (*xmlFreeFunc)(void *mem);
        To:
        typedef void (XMLCALL *xmlFreeFunc)(void *mem);
Line 66
        From:
        typedef void *(*xmlMallocFunc)(size_t size);
        To:
        typedef void *(XMLCALL *xmlMallocFunc)(size_t size);
Line 77
        From:
        typedef void *(*xmlReallocFunc)(void *mem, size_t size);
        To:
        typedef void *(XMLCALL *xmlReallocFunc)(void *mem, size_t size);


This allows us to link correctly without warning and allows the
application to run correctly.  Without this change I will get Stack
corruption errors upon calling xmlFree().

Okay, commited. I did this with the most commonly used function pointers.

Ciao,
Igor





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