Hi,

> >> -    QLIST_FOREACH(iter, &o->children, list) {
> >> +    QLIST_FOREACH_SAFE(iter, &o->children, list, next) {
> >>          handles[i++] = iter->handle;
> >>      }
> >
> > No need for SAFE here, you don't change the list.
> 
> Isn't the SAFE variant better for the case where a inotify delete event occurs
> when we are getting the object handles ?

Device emulation runs under lock, therefore all serialized, so the
inotify event processing will not run in parallel.

cheers,
  Gerd



Reply via email to