lkml.org 
[lkml]   [2006]   [Feb]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] inotify: fix one-shot support
From
Date
On Wed, 2006-02-08 at 08:52 +0100, Ingo Oeser wrote:

> See, now you can just pass IN_ONESHOT behavior flag without any
> events to shoot at, which you couldn't do before. But this makes only
> sense, if we would like to set a multi-shot mask to one-shot now.

Ack!

> Does this transition (multi shot to single shot)makes sense at all?
> Is it race-free to allow this?.

It should be okay. This was my intention in the patch.

> So my suggested fix instead of yours would be:
>
> /* don't let user-space set invalid bits: we don't want flags set */
> mask &= IN_ALL_EVENTS | IN_ONESHOT;
> if (unlikely((mask & IN_ALL_EVENTS) == 0 && !mask_add)) {
> ret = -EINVAL;
> goto out;
> }
>
> Would you like a patch on top of the one submitted by you?

Yes, because my patch was already merged by Linus.

Robert Love

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-02-08 17:22    [W:0.049 / U:0.496 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site