fsnotify currently expects everything using the generic notification infrastructure to want to send private data with the notification. fanotify has no such requirement (like inotify does) so support that as well. Signed-off-by: Eric Paris <eparis@xxxxxxxxxx> --- fs/notify/notification.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/fs/notify/notification.c b/fs/notify/notification.c index 96ffbd0..cdf203c 100644 --- a/fs/notify/notification.c +++ b/fs/notify/notification.c @@ -173,7 +173,8 @@ int fsnotify_add_notify_event(struct fsnotify_group *group, struct fsnotify_even struct fsnotify_event *last_event; /* easy to tell if priv was attached to the event */ - INIT_LIST_HEAD(&priv->event_list); + if (priv) + INIT_LIST_HEAD(&priv->event_list); /* * There is one fsnotify_event_holder embedded inside each fsnotify_event. -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html