EVBUFFER_PTR_SET -> EVBUFFER_PTR_ADD Looks like EVBUFFER_PTR_ADD should have been used instead of EVBUFFER_PTR_SET.