implement bonjour sdk in visual c++ windows forms application -


i have succesfully implemented bonjour sdk in visual c++ console app. when trying implement same code in windows forms app (visual c++) receiving weird errors related local heap problem bonjour dll.

the following assertion in file dbgheap.c fails:

/* * if assert fails, bad pointer has been passed in. may * totally bogus, or may have been allocated heap. * pointer must come 'local' heap. */ _asserte(_crtisvalidheappointer(puserdata)); 

it helpful if knew resources dealing kind of problem.

thanks lot help

you haven't provided information, 1 place start looking bit:

it may have been allocated heap

are freeing objects allocated bonjour? c runtime library bonjour.dll linked against? using same 1 (dll or static, multithreaded or not, debug or release) in forms app? using same 1 in console app?

in general it's bad idea free memory allocated in other dlls sort of reason. isn't there bonjourfree function can call deallocate objects allocated in bonjour?

alternatively may overrunning buffer , overwriting debug memory allocation boundaries indepdently on bonjour. try looking @ memory @ failing free , see if looks correct.


Comments

Popular posts from this blog

unicode - Are email addresses allowed to contain non-alphanumeric characters? -

C#: Application without a window or taskbar item (background app) that can still use Console.WriteLine() -

c++ - Convert big endian to little endian when reading from a binary file -