Robert Shearman wrote:
+ { + char *format_name = HeapAlloc(GetProcessHeap(), 0, length); + if (!format_name) + return E_OUTOFMEMORY; + GetClipboardFormatNameA(clipformat, format_name, length); + hr = IStream_Write(stream, format_name, length, NULL); + }
You might want to free format_name at the end of that block. Mike