/**
 * dupRequestData will copy the data pointed to by *data, returning a pointer
 * to a freshly allocated representation of the data.
 */
void *dupRequestData(int requestId, void *data, size_t datalen)
{
    CommandInfo *ci = &s_commandInfo[requestId];

    return ci->dispatchFunction(data, datalen);
}