Make return size_t at methods of Event and Pool

I think they should be size_t.