c
size_t total_size = ...; // Total allocated size of *pData
if (memcpy_s(&(*pData)[wpos], total_size - wpos, bptr, bplen) != 0) {
    goto fail;
}
