I use MS Visual Studio .NET 2005 (8.0), lib-files I get from Remedy 7.01 and I have problem with FreeAR...()
________________________________ From: Action Request System discussion list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Hugo Visser Sent: Tuesday, May 29, 2007 12:19 PM To: arslist@ARSLIST.ORG Subject: Re: Problem with function FreeARQualifierStruct ** Most likely you are compiling against a different msvcrt version then the Remedy API is compiled against. I've run in to this when writing plugins, aparently it's also an issue with "normal" API's. What happens is that somewhere along the line the Remedy API allocates some memory. But since the API is compiled against a different msvcrt, the memory is allocated from a different heap. When you try to free the pointer to the allocated memory in your program, the memory region cannot be free'd because it wasn't allocated on your own heap. When coding plugins, the server will pass in a struct and you should allocate memory that the server attempts to free. At this point the same problems will occur. If you provide your own FreeAR* equivalents you should be fine, since you are managing your own heap again. Unfortunately the versions of msvcrt are tied to the versions of Visual Studio. VS 6 will use msvcrt.dll, VS.NET <http://VS.NET> will use msvcrt7.dll (or something like that) etc. The C API guide has a comment about the versions of Visual Studio you should use for a particular version of the API, to prevent heap allocation problems. I'm not sure if this is also a problem on unix platforms, but I don't think so as the libc is a system component on unix, so every api that links to libc uses the same heap, if linked dynamically. Hugo _______________________________________________________________________________ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org ARSlist:"Where the Answers Are"