switch to COIBufferCreateFromMemory with COI_BUFFER_NORMAL flag as its causing less trouble