Otherwise user_cpu_usecs does not get added to the sent events.
Use the parent's creation timestamp. */
event->tv_created_ioloop = parent->tv_created_ioloop;
event->tv_created = parent->tv_created;
+ memcpy(&event->ru_last, &parent->ru_last, sizeof(parent->ru_last));
event_last_passthrough = &event->event_passthrough;
} else {
event_last_passthrough = &parent->event_passthrough;
/* Enable "user_cpu_usecs" event field to event by getting current resource
usage which will be used in consequent event_send() to calculate
cpu time. This function can be called multiple times to update the current
- resource usage. */
+ resource usage.
+
+ The "user_cpu_usecs" field is automatically inherited by passthrough events,
+ but not full events.
+*/
void event_enable_user_cpu_usecs(struct event *event);
void lib_event_init(void);