Re: Blobs n ESQL/C for Windows
Posted in 1996
cse@wetware.com (Scott Ellard) writes: >In article <4l2l2j$s5m@news2.delphi.com> TYNEELY@news.delphi.com (TYNEELY@DELPHI.COM) writes: >>I have a WFW 3.11 app that read/writes BLOBS to a Informix 5.x Online >>engine using ESQL/C 5.01WE1 for Windows. The documentation for ESQL/C >>say that if you pass in a -1 for your uffer size on a fetch Informix wil >>allocate a buffer and return the size and a pointer to this buffer. When >>does Informix actually release this buffer or is it up to my app? >It is up to your app. The memory was allocated using GlobalAllocPtr() >and should be freed using GlobalFreePtr(). These are both macros found >in <windowsx.h>. >Scott To follow up, the documentation(Informix ESQL/C for WIndows 5.01 6-5) says that "If you do subsequent fetches and the amount of data selected increases, the buffer is freed and the necessary memory is allocated". What happens if I free and Informix comes around and tries to free it again? thanks --terry